02 Nov, 2017

1 commit

  • Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the 'GPL-2.0'
    SPDX license identifier. The SPDX identifier is a legally binding
    shorthand, which can be used instead of the full boiler plate text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart and
    Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset of
    the use cases:
    - file had no licensing information it it.
    - file was a */uapi/* one with no licensing information in it,
    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to license
    had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied to
    a file was done in a spreadsheet of side by side results from of the
    output of two independent scanners (ScanCode & Windriver) producing SPDX
    tag:value files created by Philippe Ombredanne. Philippe prepared the
    base worksheet, and did an initial spot review of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537 files
    assessed. Kate Stewart did a file by file comparison of the scanner
    results in the spreadsheet to determine which SPDX license identifier(s)
    to be applied to the file. She confirmed any determination that was not
    immediately clear with lawyers working with the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:
    - Files considered eligible had to be source code files.
    - Make and config files were included as candidates if they contained >5
    lines of source
    - File already had some variant of a license header in it (even if
    Reviewed-by: Philippe Ombredanne
    Reviewed-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

13 Oct, 2012

1 commit


01 Jun, 2012

1 commit

  • This is patchset makes fatfs stop using the VFS '->write_super()' method
    for writing out the FSINFO block.

    The final goal is to get rid of the 'sync_supers()' kernel thread. This
    kernel thread wakes up every 5 seconds (by default) and calls
    '->write_super()' for all mounted file-systems. And the bad thing is that
    this is done even if all the superblocks are clean. Moreover, some
    file-systems do not even need this end they do not register the
    '->write_super()' method at all (e.g., btrfs).

    So 'sync_supers()' most often just generates useless wake-ups and wastes
    power. I am trying to make all file-systems independent of
    '->write_super()' and plan to remove 'sync_supers()' and '->write_super'
    completely once there are no more users.

    The '->write_supers()' method is mostly used by baroque file-systems like
    hfs, udf, etc. Modern file-systems like btrfs and xfs do not use it.
    This justifies removing this stuff from VFS completely and make every FS
    self-manage own superblock.

    Tested with xfstests.

    This patch:

    Preparation for further changes. It introduces a special inode
    ('fsinfo_inode') in FAT file-system which we'll later use for managing the
    FSINFO block. Note, this there is already one special inode ('fat_inode')
    which is used for managing the FAT tables.

    Introduce new 'MSDOS_FSINFO_INO' constant for this special inode. It is
    safe to do because FAT file-system does not store inode numbers on the
    media but generates them run-time.

    I've also cleaned up the comment to existing 'MSDOS_ROOT_INO' constant,
    while on it.

    Signed-off-by: Artem Bityutskiy
    Cc: OGAWA Hirofumi
    Cc: Al Viro
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Artem Bityutskiy
     

10 Feb, 2010

1 commit

  • I found that the length of a file name when created cannot exceed 255
    characters, yet, pathconf(), via statfs(), returns the maximum as 260.

    Signed-off-by: Kevin Dankwardt
    Signed-off-by: OGAWA Hirofumi

    Kevin Dankwardt
     

31 Jan, 2009

1 commit


07 Nov, 2008

2 commits

  • This adds three helpers:

    fat_make_attrs() - makes FAT attributes from inode.
    fat_make_mode() - makes mode_t from FAT attributes.
    fat_save_attrs() - saves FAT attributes to inode.

    Then this replaces: MSDOS_MKMODE() by fat_make_mode(), fat_attr() by
    fat_make_attrs(), ->i_attrs = attr & ATTR_UNUSED by fat_save_attrs().
    And for root inode, those is used with ATTR_DIR instead of bogus
    ATTR_NONE.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     
  • This splits __KERNEL__ stuff in include/msdos_fs.h into fs/fat/fat.h.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

26 Jul, 2008

3 commits

  • Provide a new mount option ("tz=UTC") for DOS (vfat/msdos) filesystems,
    allowing timestamps to be in coordinated universal time (UTC) rather than
    local time in applications where doing this is advantageous.

    In particular, portable devices that use fat/vfat (such as digital
    cameras) can benefit from using UTC in their internal clocks, thus
    avoiding daylight saving time errors and general time ambiguity issues.
    The user of the device does not have to worry about changing the time when
    moving from place or when daylight saving changes.

    The new mount option, when set, disables the counter-adjustment that Linux
    currently makes to FAT timestamp info in anticipation of the normal
    userspace time zone correction. When used in this new mode, all daylight
    saving time and time zone handling is done in userspace as is normal for
    many other filesystems (like ext3). The default mode, which remains
    unchanged, is still appropriate when mounting volumes written in Windows
    (because of its use of local time).

    I originally based this patch on one submitted last year by Paul Collins,
    but I updated it to work with current source and changed variable/option
    naming. Ogawa Hirofumi (who maintains these filesystems) and I discussed
    this patch at length on lkml, and he suggested using the option name in
    the attached version of the patch. Barry Bouwsma pointed out a good
    addition to the patch as well.

    Signed-off-by: Joe Peterson
    Signed-off-by: Paul Collins
    Acked-by: OGAWA Hirofumi
    Cc: Barry Bouwsma
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Joe Peterson
     
  • It has been impossible to set the option 'atari' of the MSDOS filesystem
    for several years. Since nobody seems to have missed it, let's remove its
    remains.

    Signed-off-by: Rene Scharfe
    Acked-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Rene Scharfe
     
  • "struct dirent" is a kernel type here, but is a **different type** in
    userspace! This means both the structure and the IOCTL number is wrong!

    So, this adds new "struct __fat_dirent" to generate correct IOCTL number.
    And kernel stuff moves to under __KERNEL__.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

09 Jun, 2008

1 commit

  • Commit 73f20e58b1d586e9f6d3ddc3aad872829aca7743 ("FAT_VALID_MEDIA():
    remove pointless test") wrongly added the new fat_valid_media() function
    to the userspace-visible part of include/linux/msdos_fs.h

    Move it to the part of include/linux/msdos_fs.h that is not exported to
    userspace.

    Reported-by: Onur Küçük
    Reported-by: S.Çağlar Onur
    Signed-off-by: Adrian Bunk
    Acked-by: OGAWA Hirofumi
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     

28 Apr, 2008

4 commits

  • The on-disk media specification field in FAT is only 8-bits, so testing for

    Acked-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrew Morton
     
  • Currently, free_clusters is not updated until it is trusted, because
    Windows doesn't update it correctly.

    But if user is using FAT driver of Linux, it updates free_clusters
    correctly. Instead, this updates it even if it's untrusted, so if
    free_clustes is correct, now keep correct value.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     
  • Normally utime(2) checks current process is owner of the file, or it
    has CAP_FOWNER capability. But FAT filesystem doesn't have uid/gid as
    on disk info, so normal check is too unflexible.

    With this option you can relax it.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     
  • - Rename fat_notify_change() to fat_setattr()
    - check_mode() cleanup
    - Change layout of code

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

17 Jul, 2007

1 commit

  • This patch fixes the following warnings.

    fs/fat/dir.c: In function 'fat_parse_long':
    include/linux/msdos_fs.h:294: warning: array subscript is above array bounds
    include/linux/msdos_fs.h:295: warning: array subscript is above array bounds
    include/linux/msdos_fs.h:295: warning: array subscript is above array bounds

    The ->name is defined as "name[8], ext[3]", but fat_checksum() uses
    those as name[11]. There is no actual problem, but it's not a good manner.

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

09 May, 2007

1 commit

  • It seems that the recent Windows changed specification, and it's
    undocumented. Windows doesn't update ->free_clusters correctly.

    This patch doesn't use ->free_clusters by default. (instead, add "usefree"
    for forcing to use it)

    Signed-off-by: OGAWA Hirofumi
    Cc: Juergen Beisert
    Cc: Andreas Schwab
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

13 Feb, 2007

1 commit

  • Many struct inode_operations in the kernel can be "const". Marking them const
    moves these to the .rodata section, which avoids false sharing with potential
    dirty data. In addition it'll catch accidental writes at compile time to
    these shared resources.

    Signed-off-by: Arjan van de Ven
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Arjan van de Ven
     

17 Nov, 2006

1 commit


30 Sep, 2006

1 commit

  • Fat is commonly used on removable media. Mounting with -o flush tells the
    FS to write things to disk as quickly as possible. It is like -o sync, but
    much faster (and not as safe).

    Signed-off-by: Chris Mason
    Cc: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Chris Mason
     

24 Sep, 2006

1 commit


29 Mar, 2006

2 commits

  • This is a conversion to make the various file_operations structs in fs/
    const. Basically a regexp job, with a few manual fixups

    The goal is both to increase correctness (harder to accidentally write to
    shared datastructures) and reducing the false sharing of cachelines with
    things that get dirty in .data (while .rodata is nicely read only and thus
    cache clean)

    Signed-off-by: Arjan van de Ven
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Arjan van de Ven
     
  • Add proper prototypes for fat_cache_init() and fat_cache_destroy() in
    msdos_fs.h.

    Signed-off-by: Adrian Bunk
    Acked-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     

23 Mar, 2006

1 commit


22 Mar, 2006

1 commit


09 Jan, 2006

1 commit

  • This patch add to support of ->direct_IO() for mostly read.

    The user of this seems to want to use for streaming read. So, current direct
    I/O has limitation, it can only overwrite. (For write operation, mainly we
    need to handle the hole etc..)

    Signed-off-by: OGAWA Hirofumi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    OGAWA Hirofumi
     

31 Oct, 2005

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds