25 Nov, 2020

1 commit

  • The memory leak addressed by commit fe5186cf12e3 is a false positive:
    all allocations are recorded in a linked list, and freed when the
    filesystem is unmounted. This leads to double frees, and as reported
    by David, leads to crashes if SLUB is configured to self destruct when
    double frees occur.

    So drop the redundant kfree() again, and instead, mark the offending
    pointer variable so the allocation is ignored by kmemleak.

    Cc: Vamshi K Sthambamkadi
    Fixes: fe5186cf12e3 ("efivarfs: fix memory leak in efivarfs_create()")
    Reported-by: David Laight
    Signed-off-by: Ard Biesheuvel

    Ard Biesheuvel
     

26 Oct, 2020

1 commit

  • kmemleak report:
    unreferenced object 0xffff9b8915fcb000 (size 4096):
    comm "efivarfs.sh", pid 2360, jiffies 4294920096 (age 48.264s)
    hex dump (first 32 bytes):
    2d 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 -...............
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
    backtrace:
    [] kmem_cache_alloc_trace+0x155/0x4b0
    [] efivarfs_create+0x6e/0x1a0
    [] path_openat+0xe4b/0x1120
    [] do_filp_open+0x91/0x100
    [] do_sys_openat2+0x20c/0x2d0
    [] do_sys_open+0x46/0x80
    [] __x64_sys_openat+0x20/0x30
    [] do_syscall_64+0x38/0x90
    [] entry_SYSCALL_64_after_hwframe+0x44/0xa9

    In efivarfs_create(), inode->i_private is setup with efivar_entry
    object which is never freed.

    Cc:
    Signed-off-by: Vamshi K Sthambamkadi
    Link: https://lore.kernel.org/r/20201023115429.GA2479@cosmos
    Signed-off-by: Ard Biesheuvel

    Vamshi K Sthambamkadi
     

26 Sep, 2020

1 commit

  • Without this patch efivarfs_alloc_dentry creates dentries with slashes in
    their name if the respective EFI variable has slashes in its name. This in
    turn causes EIO on getdents64, which prevents a complete directory listing
    of /sys/firmware/efi/efivars/.

    This patch replaces the invalid shlashes with exclamation marks like
    kobject_set_name_vargs does for /sys/firmware/efi/vars/ to have consistently
    named dentries under /sys/firmware/efi/vars/ and /sys/firmware/efi/efivars/.

    Signed-off-by: Michael Schaller
    Link: https://lore.kernel.org/r/20200925074502.150448-1-misch@google.com
    Signed-off-by: Ard Biesheuvel

    Michael Schaller
     

09 Jul, 2020

1 commit

  • Commit

    bf67fad19e493b ("efi: Use more granular check for availability for variable services")

    introduced a check into the efivarfs, efi-pstore and other drivers that
    aborts loading of the module if not all three variable runtime services
    (GetVariable, SetVariable and GetNextVariable) are supported. However, this
    results in efivarfs being unavailable entirely if only SetVariable support
    is missing, which is only needed if you want to make any modifications.
    Also, efi-pstore and the sysfs EFI variable interface could be backed by
    another implementation of the 'efivars' abstraction, in which case it is
    completely irrelevant which services are supported by the EFI firmware.

    So make the generic 'efivars' abstraction dependent on the availibility of
    the GetVariable and GetNextVariable EFI runtime services, and add a helper
    'efivar_supports_writes()' to find out whether the currently active efivars
    abstraction supports writes (and wire it up to the availability of
    SetVariable for the generic one).

    Then, use the efivar_supports_writes() helper to decide whether to permit
    efivarfs to be mounted read-write, and whether to enable efi-pstore or the
    sysfs EFI variable interface altogether.

    Fixes: bf67fad19e493b ("efi: Use more granular check for availability for variable services")
    Reported-by: Heinrich Schuchardt
    Acked-by: Ilias Apalodimas
    Tested-by: Ilias Apalodimas
    Signed-off-by: Ard Biesheuvel

    Ard Biesheuvel
     

15 Jun, 2020

2 commits

  • Applications that read EFI variables may see a return
    value of -EINTR if they exceed the rate limit and a
    signal delivery is attempted while the process is sleeping.

    This is quite surprising to the application, which probably
    doesn't have code to handle it.

    Change the interruptible sleep to a non-interruptible one.

    Reported-by: Lennart Poettering
    Signed-off-by: Tony Luck
    Link: https://lore.kernel.org/r/20200528194905.690-3-tony.luck@intel.com
    Signed-off-by: Ard Biesheuvel

    Tony Luck
     
  • Some applications want to be able to see when EFI variables
    have been updated.

    Update the modification time for successful writes.

    Reported-by: Lennart Poettering
    Signed-off-by: Tony Luck
    Link: https://lore.kernel.org/r/20200528194905.690-2-tony.luck@intel.com
    Signed-off-by: Ard Biesheuvel

    Tony Luck
     

24 Feb, 2020

1 commit


20 Jul, 2019

1 commit

  • Pull vfs mount updates from Al Viro:
    "The first part of mount updates.

    Convert filesystems to use the new mount API"

    * 'work.mount0' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (63 commits)
    mnt_init(): call shmem_init() unconditionally
    constify ksys_mount() string arguments
    don't bother with registering rootfs
    init_rootfs(): don't bother with init_ramfs_fs()
    vfs: Convert smackfs to use the new mount API
    vfs: Convert selinuxfs to use the new mount API
    vfs: Convert securityfs to use the new mount API
    vfs: Convert apparmorfs to use the new mount API
    vfs: Convert openpromfs to use the new mount API
    vfs: Convert xenfs to use the new mount API
    vfs: Convert gadgetfs to use the new mount API
    vfs: Convert oprofilefs to use the new mount API
    vfs: Convert ibmasmfs to use the new mount API
    vfs: Convert qib_fs/ipathfs to use the new mount API
    vfs: Convert efivarfs to use the new mount API
    vfs: Convert configfs to use the new mount API
    vfs: Convert binfmt_misc to use the new mount API
    convenience helper: get_tree_single()
    convenience helper get_tree_nodev()
    vfs: Kill sget_userns()
    ...

    Linus Torvalds
     

13 Jul, 2019

1 commit

  • Pull common SETFLAGS/FSSETXATTR parameter checking from Darrick Wong:
    "Here's a patch series that sets up common parameter checking functions
    for the FS_IOC_SETFLAGS and FS_IOC_FSSETXATTR ioctl implementations.

    The goal here is to reduce the amount of behaviorial variance between
    the filesystems where those ioctls originated (ext2 and XFS,
    respectively) and everybody else.

    - Standardize parameter checking for the SETFLAGS and FSSETXATTR
    ioctls (which were the file attribute setters for ext4 and xfs and
    have now been hoisted to the vfs)

    - Only allow the DAX flag to be set on files and directories"

    * tag 'vfs-fix-ioctl-checking-3' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
    vfs: only allow FSSETXATTR to set DAX flag on files and dirs
    vfs: teach vfs_ioc_fssetxattr_check to check extent size hints
    vfs: teach vfs_ioc_fssetxattr_check to check project id info
    vfs: create a generic checking function for FS_IOC_FSSETXATTR
    vfs: create a generic checking and prep function for FS_IOC_SETFLAGS

    Linus Torvalds
     

05 Jul, 2019

1 commit

  • Convert the efivarfs filesystem to the new internal mount API as the old
    one will be obsoleted and removed. This allows greater flexibility in
    communication of mount parameters between userspace, the VFS and the
    filesystem.

    [AV: get rid of efivarfs_sb nonsense - it has never been used]

    See Documentation/filesystems/mount_api.txt for more information.

    Signed-off-by: David Howells
    cc: Matthew Garrett
    cc: Jeremy Kerr
    cc: Ard Biesheuvel
    cc: linux-efi@vger.kernel.org
    Signed-off-by: Al Viro

    David Howells
     

01 Jul, 2019

1 commit

  • Create a generic function to check incoming FS_IOC_SETFLAGS flag values
    and later prepare the inode for updates so that we can standardize the
    implementations that follow ext4's flag values.

    Note that the efivarfs implementation no longer fails a no-op SETFLAGS
    without CAP_LINUX_IMMUTABLE since that's the behavior in ext*.

    Signed-off-by: Darrick J. Wong
    Reviewed-by: Jan Kara
    Reviewed-by: Christoph Hellwig
    Acked-by: David Sterba
    Reviewed-by: Bob Peterson

    Darrick J. Wong
     

19 Jun, 2019

1 commit

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation #

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 4122 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Enrico Weigelt
    Reviewed-by: Kate Stewart
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

21 May, 2019

1 commit


22 Jul, 2018

1 commit

  • uuid_le_to_bin() is deprecated API and take into consideration that variable,
    to where we store parsed data, is type of guid_t we switch to guid_parse()
    for sake of consistency.

    While here, add error checking to it.

    Signed-off-by: Andy Shevchenko
    Signed-off-by: Ard Biesheuvel
    Cc: Hans de Goede
    Cc: Linus Torvalds
    Cc: Lukas Wunner
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: linux-efi@vger.kernel.org
    Link: http://lkml.kernel.org/r/20180720014726.24031-10-ard.biesheuvel@linaro.org
    Signed-off-by: Ingo Molnar

    Andy Shevchenko
     

23 Feb, 2018

1 commit

  • Each read from a file in efivarfs results in two calls to EFI
    (one to get the file size, another to get the actual data).

    On X86 these EFI calls result in broadcast system management
    interrupts (SMI) which affect performance of the whole system.
    A malicious user can loop performing reads from efivarfs bringing
    the system to its knees.

    Linus suggested per-user rate limit to solve this.

    So we add a ratelimit structure to "user_struct" and initialize
    it for the root user for no limit. When allocating user_struct for
    other users we set the limit to 100 per second. This could be used
    for other places that want to limit the rate of some detrimental
    user action.

    In efivarfs if the limit is exceeded when reading, we take an
    interruptible nap for 50ms and check the rate limit again.

    Signed-off-by: Tony Luck
    Acked-by: Ard Biesheuvel
    Signed-off-by: Linus Torvalds

    Luck, Tony
     

11 Jul, 2017

1 commit

  • Kill off s_options, save/replace_mount_options() and generic_show_options()
    as all filesystems now implement ->show_options() for themselves. This
    should make it easier to implement a context-based mount where the mount
    options can be passed individually over a file descriptor.

    Signed-off-by: David Howells
    Signed-off-by: Al Viro

    David Howells
     

11 Oct, 2016

1 commit

  • Pull more vfs updates from Al Viro:
    ">rename2() work from Miklos + current_time() from Deepa"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
    fs: Replace current_fs_time() with current_time()
    fs: Replace CURRENT_TIME_SEC with current_time() for inode timestamps
    fs: Replace CURRENT_TIME with current_time() for inode timestamps
    fs: proc: Delete inode time initializations in proc_alloc_inode()
    vfs: Add current_time() api
    vfs: add note about i_op->rename changes to porting
    fs: rename "rename2" i_op to "rename"
    vfs: remove unused i_op->rename
    fs: make remaining filesystems use .rename2
    libfs: support RENAME_NOREPLACE in simple_rename()
    fs: support RENAME_NOREPLACE for local filesystems
    ncpfs: fix unused variable warning

    Linus Torvalds
     

28 Sep, 2016

1 commit

  • CURRENT_TIME macro is not appropriate for filesystems as it
    doesn't use the right granularity for filesystem timestamps.
    Use current_time() instead.

    CURRENT_TIME is also not y2038 safe.

    This is also in preparation for the patch that transitions
    vfs timestamps to use 64 bit time and hence make them
    y2038 safe. As part of the effort current_time() will be
    extended to do range checks. Hence, it is necessary for all
    file system timestamps to use current_time(). Also,
    current_time() will be transitioned along with vfs to be
    y2038 safe.

    Note that whenever a single call to current_time() is used
    to change timestamps in different inodes, it is because they
    share the same time granularity.

    Signed-off-by: Deepa Dinamani
    Reviewed-by: Arnd Bergmann
    Acked-by: Felipe Balbi
    Acked-by: Steven Whitehouse
    Acked-by: Ryusuke Konishi
    Acked-by: David Sterba
    Signed-off-by: Al Viro

    Deepa Dinamani
     

09 Sep, 2016

2 commits

  • Julia reported that we may double free 'name' in efivarfs_callback(),
    and that this bug was introduced by commit 0d22f33bc37c ("efi: Don't
    use spinlocks for efi vars").

    Move one of the kfree()s until after the point at which we know we are
    definitely on the success path.

    Reported-by: Julia Lawall
    Acked-by: Julia Lawall
    Cc: Ard Biesheuvel
    Cc: Sylvain Chouleur
    Signed-off-by: Matt Fleming

    Matt Fleming
     
  • All efivars operations are protected by a spinlock which prevents
    interruptions and preemption. This is too restricted, we just need a
    lock preventing concurrency.
    The idea is to use a semaphore of count 1 and to have two ways of
    locking, depending on the context:
    - In interrupt context, we call down_trylock(), if it fails we return
    an error
    - In normal context, we call down_interruptible()

    We don't use a mutex here because the mutex_trylock() function must not
    be called from interrupt context, whereas the down_trylock() can.

    Signed-off-by: Sylvain Chouleur
    Signed-off-by: Ard Biesheuvel
    Cc: Leif Lindholm
    Cc: Mark Rutland
    Cc: Sylvain Chouleur
    Signed-off-by: Matt Fleming

    Sylvain Chouleur
     

01 Aug, 2016

1 commit


11 Jun, 2016

1 commit

  • We always mixed in the parent pointer into the dentry name hash, but we
    did it late at lookup time. It turns out that we can simplify that
    lookup-time action by salting the hash with the parent pointer early
    instead of late.

    A few other users of our string hashes also wanted to mix in their own
    pointers into the hash, and those are updated to use the same mechanism.

    Hash users that don't have any particular initial salt can just use the
    NULL pointer as a no-salt.

    Cc: Vegard Nossum
    Cc: George Spelvin
    Cc: Al Viro
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

21 May, 2016

1 commit

  • Instead of opencoding let's use generic UUID library functions here.

    Signed-off-by: Andy Shevchenko
    Reviewed-by: Matt Fleming
    Cc: Dmitry Kasatkin
    Cc: Mimi Zohar
    Cc: Rasmus Villemoes
    Cc: Arnd Bergmann
    Cc: "Theodore Ts'o"
    Cc: Al Viro
    Cc: Jens Axboe
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Shevchenko
     

07 May, 2016

2 commits

  • There are no callers except through the file_operations struct below
    this, so it should be static like everything else here.

    Signed-off-by: Peter Jones
    Signed-off-by: Matt Fleming
    Cc: Andy Lutomirski
    Cc: Ard Biesheuvel
    Cc: Borislav Petkov
    Cc: Brian Gerst
    Cc: Denys Vlasenko
    Cc: H. Peter Anvin
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: linux-efi@vger.kernel.org
    Link: http://lkml.kernel.org/r/1462570771-13324-6-git-send-email-matt@codeblueprint.co.uk
    Signed-off-by: Ingo Molnar

    Peter Jones
     
  • The parameters atomic and duplicates of efivar_init always have opposite
    values. Drop the parameter atomic, replace the uses of !atomic with
    duplicates, and update the call sites accordingly.

    The code using duplicates is slightly reorganized with an 'else', to avoid
    duplicating the lock code.

    Signed-off-by: Julia Lawall
    Signed-off-by: Matt Fleming
    Cc: Andy Lutomirski
    Cc: Ard Biesheuvel
    Cc: Borislav Petkov
    Cc: Brian Gerst
    Cc: Denys Vlasenko
    Cc: H. Peter Anvin
    Cc: Jeremy Kerr
    Cc: Linus Torvalds
    Cc: Matthew Garrett
    Cc: Peter Zijlstra
    Cc: Saurabh Sengar
    Cc: Thomas Gleixner
    Cc: Vaishali Thakkar
    Cc: linux-efi@vger.kernel.org
    Link: http://lkml.kernel.org/r/1462570771-13324-5-git-send-email-matt@codeblueprint.co.uk
    Signed-off-by: Ingo Molnar

    Julia Lawall
     

05 Apr, 2016

1 commit

  • PAGE_CACHE_{SIZE,SHIFT,MASK,ALIGN} macros were introduced *long* time
    ago with promise that one day it will be possible to implement page
    cache with bigger chunks than PAGE_SIZE.

    This promise never materialized. And unlikely will.

    We have many places where PAGE_CACHE_SIZE assumed to be equal to
    PAGE_SIZE. And it's constant source of confusion on whether
    PAGE_CACHE_* or PAGE_* constant should be used in a particular case,
    especially on the border between fs and mm.

    Global switching to PAGE_CACHE_SIZE != PAGE_SIZE would cause to much
    breakage to be doable.

    Let's stop pretending that pages in page cache are special. They are
    not.

    The changes are pretty straight-forward:

    - << (PAGE_CACHE_SHIFT - PAGE_SHIFT) -> ;

    - >> (PAGE_CACHE_SHIFT - PAGE_SHIFT) -> ;

    - PAGE_CACHE_{SIZE,SHIFT,MASK,ALIGN} -> PAGE_{SIZE,SHIFT,MASK,ALIGN};

    - page_cache_get() -> get_page();

    - page_cache_release() -> put_page();

    This patch contains automated changes generated with coccinelle using
    script below. For some reason, coccinelle doesn't patch header files.
    I've called spatch for them manually.

    The only adjustment after coccinelle is revert of changes to
    PAGE_CAHCE_ALIGN definition: we are going to drop it later.

    There are few places in the code where coccinelle didn't reach. I'll
    fix them manually in a separate patch. Comments and documentation also
    will be addressed with the separate patch.

    virtual patch

    @@
    expression E;
    @@
    - E << (PAGE_CACHE_SHIFT - PAGE_SHIFT)
    + E

    @@
    expression E;
    @@
    - E >> (PAGE_CACHE_SHIFT - PAGE_SHIFT)
    + E

    @@
    @@
    - PAGE_CACHE_SHIFT
    + PAGE_SHIFT

    @@
    @@
    - PAGE_CACHE_SIZE
    + PAGE_SIZE

    @@
    @@
    - PAGE_CACHE_MASK
    + PAGE_MASK

    @@
    expression E;
    @@
    - PAGE_CACHE_ALIGN(E)
    + PAGE_ALIGN(E)

    @@
    expression E;
    @@
    - page_cache_get(E)
    + get_page(E)

    @@
    expression E;
    @@
    - page_cache_release(E)
    + put_page(E)

    Signed-off-by: Kirill A. Shutemov
    Acked-by: Michal Hocko
    Signed-off-by: Linus Torvalds

    Kirill A. Shutemov
     

11 Feb, 2016

1 commit

  • "rm -rf" is bricking some peoples' laptops because of variables being
    used to store non-reinitializable firmware driver data that's required
    to POST the hardware.

    These are 100% bugs, and they need to be fixed, but in the mean time it
    shouldn't be easy to *accidentally* brick machines.

    We have to have delete working, and picking which variables do and don't
    work for deletion is quite intractable, so instead make everything
    immutable by default (except for a whitelist), and make tools that
    aren't quite so broad-spectrum unset the immutable flag.

    Signed-off-by: Peter Jones
    Tested-by: Lee, Chun-Yi
    Acked-by: Matthew Garrett
    Signed-off-by: Matt Fleming

    Peter Jones
     

10 Feb, 2016

1 commit


23 Jan, 2016

1 commit

  • parallel to mutex_{lock,unlock,trylock,is_locked,lock_nested},
    inode_foo(inode) being mutex_foo(&inode->i_mutex).

    Please, use those for access to ->i_mutex; over the coming cycle
    ->i_mutex will become rwsem, with ->lookup() done with it held
    only shared.

    Signed-off-by: Al Viro

    Al Viro
     

07 May, 2015

1 commit

  • Pull x86 fixes from Ingo Molnar:
    "EFI fixes, and FPU fix, a ticket spinlock boundary condition fix and
    two build fixes"

    * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    x86/fpu: Always restore_xinit_state() when use_eager_cpu()
    x86: Make cpu_tss available to external modules
    efi: Fix error handling in add_sysfs_runtime_map_entry()
    x86/spinlocks: Fix regression in spinlock contention detection
    x86/mm: Clean up types in xlate_dev_mem_ptr()
    x86/efi: Store upper bits of command line buffer address in ext_cmd_line_ptr
    efivarfs: Ensure VariableName is NUL-terminated

    Linus Torvalds
     

17 Apr, 2015

1 commit

  • Some buggy firmware implementations update VariableNameSize on success
    such that it does not include the final NUL character which results in
    garbage in the efivarfs name entries. Use kzalloc on the efivar_entry
    (as is done in efivars.c) to ensure that the name is always
    NUL-terminated.

    The buggy firmware is:
    BIOS Information
    Vendor: Intel Corp.
    Version: S1200RP.86B.02.02.0005.102320140911
    Release Date: 10/23/2014
    BIOS Revision: 4.6
    System Information
    Manufacturer: Intel Corporation
    Product Name: S1200RP_SE

    Signed-off-by: Ross Lagerwall
    Acked-by: Matthew Garrett
    Cc: Jeremy Kerr
    Cc:
    Signed-off-by: Matt Fleming

    Ross Lagerwall
     

16 Apr, 2015

1 commit


30 Jan, 2015

1 commit

  • Pull EFI updates from Matt Fleming:

    " - Move efivarfs from the misc filesystem section to pseudo filesystem,
    since that's a more logical and accurate place - Leif Lindholm

    - Update efibootmgr URL in Kconfig help - Peter Jones

    - Improve accuracy of EFI guid function names - Borislav Petkov

    - Expose firmware platform size in sysfs for the benefit of EFI boot
    loader installers and other utilities - Steve McIntyre

    - Cleanup __init annotations for arm64/efi code - Ard Biesheuvel

    - Mark the UIE as unsupported for rtc-efi - Ard Biesheuvel

    - Fix memory leak in error code path of runtime map code - Dan Carpenter

    - Improve robustness of get_memory_map() by removing assumptions on the
    size of efi_memory_desc_t (which could change in future spec
    versions) and querying the firmware instead of guessing about the
    memmap size - Ard Biesheuvel

    - Remove superfluous guid unparse calls - Ivan Khoronzhuk

    - Delete unnecessary chosen@0 DT node FDT code since was duplicated
    from code in drivers/of and is entirely unnecessary - Leif Lindholm

    There's nothing super scary, mainly cleanups, and a merge from Ricardo who
    kindly picked up some patches from the linux-efi mailing list while I
    was out on annual leave in December.

    Perhaps the biggest risk is the get_memory_map() change from Ard, which
    changes the way that both the arm64 and x86 EFI boot stub build the
    early memory map. It would be good to have it bake in linux-next for a
    while.
    "

    Signed-off-by: Ingo Molnar

    Ingo Molnar
     

12 Jan, 2015

1 commit


08 Jan, 2015

1 commit


05 Jan, 2015

1 commit

  • efivars is currently enabled under MISC_FILESYSTEMS, which is decribed
    as "such as filesystems that came from other operating systems".
    In reality, it is a pseudo filesystem, providing access to the kernel
    UEFI variable interface.

    Since this is the preferred interface for accessing UEFI variables, over
    the legacy efivars interface, also build it by default as a module if
    CONFIG_EFI.

    Signed-off-by: Leif Lindholm
    Signed-off-by: Matt Fleming

    Leif Lindholm
     

11 Dec, 2014

1 commit

  • Pull VFS changes from Al Viro:
    "First pile out of several (there _definitely_ will be more). Stuff in
    this one:

    - unification of d_splice_alias()/d_materialize_unique()

    - iov_iter rewrite

    - killing a bunch of ->f_path.dentry users (and f_dentry macro).

    Getting that completed will make life much simpler for
    unionmount/overlayfs, since then we'll be able to limit the places
    sensitive to file _dentry_ to reasonably few. Which allows to have
    file_inode(file) pointing to inode in a covered layer, with dentry
    pointing to (negative) dentry in union one.

    Still not complete, but much closer now.

    - crapectomy in lustre (dead code removal, mostly)

    - "let's make seq_printf return nothing" preparations

    - assorted cleanups and fixes

    There _definitely_ will be more piles"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (63 commits)
    copy_from_iter_nocache()
    new helper: iov_iter_kvec()
    csum_and_copy_..._iter()
    iov_iter.c: handle ITER_KVEC directly
    iov_iter.c: convert copy_to_iter() to iterate_and_advance
    iov_iter.c: convert copy_from_iter() to iterate_and_advance
    iov_iter.c: get rid of bvec_copy_page_{to,from}_iter()
    iov_iter.c: convert iov_iter_zero() to iterate_and_advance
    iov_iter.c: convert iov_iter_get_pages_alloc() to iterate_all_kinds
    iov_iter.c: convert iov_iter_get_pages() to iterate_all_kinds
    iov_iter.c: convert iov_iter_npages() to iterate_all_kinds
    iov_iter.c: iterate_and_advance
    iov_iter.c: macros for iterating over iov_iter
    kill f_dentry macro
    dcache: fix kmemcheck warning in switch_names
    new helper: audit_file()
    nfsd_vfs_write(): use file_inode()
    ncpfs: use file_inode()
    kill f_dentry uses
    lockd: get rid of ->f_path.dentry->d_sb
    ...

    Linus Torvalds
     

20 Nov, 2014

1 commit


12 Nov, 2014

1 commit

  • There is no need to keep the module loaded when it serves no function in
    case the EFI runtime services are disabled. Return an error in this case
    so loading the module will fail.

    Also supply a module_exit function to allow unloading the module.

    Last, but not least, set the owner of the file_system_type struct.

    Cc: Jeremy Kerr
    Cc: Matthew Garrett
    Signed-off-by: Mathias Krause
    Signed-off-by: Matt Fleming

    Mathias Krause
     

05 Jun, 2014

1 commit