1. 31 Aug, 2017 2 commits
  2. 30 Aug, 2017 3 commits
  3. 25 Aug, 2017 3 commits
    • Bob Peterson's avatar
      GFS2: Fix up some sparse warnings · 27c3b415
      Bob Peterson authored
      This patch cleans up various pieces of GFS2 to avoid sparse errors.
      This doesn't fix them all, but it fixes several. The first error,
      in function glock_hash_walk was a genuine bug where the rhashtable
      could be started and not stopped.
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      27c3b415
    • Andreas Gruenbacher's avatar
      gfs2: Silence gcc format-truncation warning · 561b7969
      Andreas Gruenbacher authored
      Enlarge sd_fsname to be big enough for the longest long lock table name
      and an arbitrary journal number.  This silences two -Wformat-truncation
      warnings with gcc 7.1.1.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      561b7969
    • Bob Peterson's avatar
      GFS2: Withdraw for IO errors writing to the journal or statfs · 942b0cdd
      Bob Peterson authored
      Before this patch, if GFS2 encountered IO errors while writing to
      the journal, it would not report the problem, so they would go
      unnoticed, sometimes for many hours. Sometimes this would only be
      noticed later, when recovery tried to do journal replay and failed
      due to invalid metadata at the blocks that resulted in IO errors.
      
      This patch makes GFS2's log daemon check for IO errors. If it
      encounters one, it withdraws from the file system and reports
      why in dmesg. A similar action is taken when IO errors occur when
      writing to the system statfs file.
      
      These errors are also reported back to any callers of fsync, since
      that requires the journal to be flushed. Therefore, any IO errors
      that would previously go unnoticed are now noticed and the file
      system is withdrawn as early as possible, thus preventing further
      file system damage.
      
      Also note that this reintroduces superblock variable sd_log_error,
      which Christoph removed with commit f729b66f.
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      942b0cdd
  4. 15 Aug, 2017 1 commit
    • Thomas Tai's avatar
      gfs2: fix slab corruption during mounting and umounting gfs file system · cc1dfa8b
      Thomas Tai authored
      When using cman-3.0.12.1 and gfs2-utils-3.0.12.1, mounting and
      unmounting GFS2 file system would cause kernel to hang. The slab
      allocator suggests that it is likely a double free memory corruption.
      The issue is traced back to v3.9-rc6 where a patch is submitted to
      use kzalloc() for storing a bitmap instead of using a local variable.
      The intention is to allocate memory during mount and to free memory
      during unmount. The original patch misses a code path which has
      already freed the memory and caused memory corruption. This patch sets
      the memory pointer to NULL after the memory is freed, so that double
      free memory corruption will not happen.
      
      gdlm_mount()
        '-- set_recover_size() which use kzalloc()
        '-- if dlm does not support ops callbacks then
                '--- free_recover_size() which use kfree()
      
      gldm_unmount()
        '-- free_recover_size() which use kfree()
      
      Previous patch which introduced the double free issue is
      commit 57c7310b ("GFS2: use kmalloc for lvb bitmap")
      Signed-off-by: default avatarThomas Tai <thomas.tai@oracle.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      Reviewed-by: default avatarLiam R. Howlett <Liam.Howlett@Oracle.com>
      cc1dfa8b
  5. 10 Aug, 2017 6 commits
    • Abhi Das's avatar
      gfs2: forcibly flush ail to relieve memory pressure · b066a4ee
      Abhi Das authored
      On systems with low memory, it is possible for gfs2 to infinitely
      loop in balance_dirty_pages() under heavy IO (creating sparse files).
      
      balance_dirty_pages() attempts to write out the dirty pages via
      gfs2_writepages() but none are found because these dirty pages are
      being used by the journaling code in the ail. Normally, the journal
      has an upper threshold which when hit triggers an automatic flush
      of the ail. But this threshold can be higher than the number of
      allowable dirty pages and result in the ail never being flushed.
      
      This patch forces an ail flush when gfs2_writepages() fails to write
      anything. This is a good indication that the ail might be holding
      some dirty pages.
      Signed-off-by: default avatarAbhi Das <adas@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      b066a4ee
    • Andreas Gruenbacher's avatar
      gfs2: Clean up waiting on glocks · a91323e2
      Andreas Gruenbacher authored
      The prepare_to_wait_on_glock and finish_wait_on_glock functions introduced in
      commit 56a365be "gfs2: gfs2_glock_get: Wait on freeing glocks" are
      better removed, resulting in cleaner code.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      a91323e2
    • Andreas Gruenbacher's avatar
      gfs2: Defer deleting inodes under memory pressure · 6a1c8f6d
      Andreas Gruenbacher authored
      When under memory pressure and an inode's link count has dropped to
      zero, defer deleting the inode to the delete workqueue.  This avoids
      calling into DLM under memory pressure, which can deadlock.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      6a1c8f6d
    • Andreas Gruenbacher's avatar
      gfs2: gfs2_evict_inode: Put glocks asynchronously · 71c1b213
      Andreas Gruenbacher authored
      gfs2_evict_inode is called to free inodes under memory pressure.  The
      function calls into DLM when an inode's last cluster-wide reference goes
      away (remote unlink) and to release the glock and associated DLM lock
      before finally destroying the inode.  However, if DLM is blocked on
      memory to become available, calling into DLM again will deadlock.
      
      Avoid that by decoupling releasing glocks from destroying inodes in that
      case: with gfs2_glock_queue_put, glocks will be dequeued asynchronously
      in work queue context, when the associated inodes have likely already
      been destroyed.
      
      With this change, inodes can end up being unlinked, remote-unlink can be
      triggered, and then the inode can be reallocated before all
      remote-unlink callbacks are processed.  To detect that, revalidate the
      link count in gfs2_evict_inode to make sure we're not deleting an
      allocated, referenced inode.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      71c1b213
    • Andreas Gruenbacher's avatar
      gfs2: Get rid of gfs2_set_nlink · eebd2e81
      Andreas Gruenbacher authored
      Remove gfs2_set_nlink which prevents the link count of an inode from
      becoming non-zero once it has reached zero.  The next commit reduces the
      amount of waiting on glocks when an inode is evicted from memory.  With
      that, an inode can become reallocated before all the remote-unlink
      callbacks from a previous delete are processed, which causes the link
      count to change from zero to non-zero.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      eebd2e81
    • Andreas Gruenbacher's avatar
      gfs2: gfs2_glock_get: Wait on freeing glocks · 0515480a
      Andreas Gruenbacher authored
      Keep glocks in their hash table until they are freed instead of removing
      them when their last reference is dropped.  This allows to wait for any
      previous instances of a glock to go away in gfs2_glock_get before
      creating a new glocks.
      
      Special thanks to Andy Price for finding and fixing a problem which also
      required us to delete the rcu_read_unlock from the error case in function
      gfs2_glock_get.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      0515480a
  6. 09 Aug, 2017 6 commits
  7. 21 Jul, 2017 4 commits
    • Bob Peterson's avatar
      GFS2: Set gl_object in inode lookup only after block type check · 4d7c18c7
      Bob Peterson authored
      Before this patch, the inode glock's gl_object was set after a
      reference was acquired, but before the block type was verified.
      In cases where the block was unlinked, then freed and reused on
      another node, a residule delete callback (delete_work) would try
      to look up the inode, eventually failing the block check, but
      only after it overwrites gl_object with a pointer to the wrong
      inode. This patch moves the assignment of gl_object after the
      block check so it won't be improperly overwritten.
      
      Likewise, at the end of the function, gfs2_inode_lookup was
      clearing gl_object after it unlocked the glock, which meant
      another process might free the glock in the meantime. This
      patch guards against that case.
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      Reviewed-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      4d7c18c7
    • Bob Peterson's avatar
      GFS2: Introduce helper for clearing gl_object · df3d87bd
      Bob Peterson authored
      This patch introduces a new helper function in glock.h that
      clears gl_object, with an added integrity check. An additional
      integrity check has been added to glock_set_object, plus comments.
      This is step 1 in a series to ensure gl_object integrity.
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      Reviewed-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      df3d87bd
    • Coly Li's avatar
      gfs2: add flag REQ_PRIO for metadata I/O · e477b24b
      Coly Li authored
      When gfs2 does metadata I/O, only REQ_META is used as a metadata hint of
      the bio. But flag REQ_META is just a hint for block trace, not for block
      layer code to handle a bio as metadata request.
      
      For some of metadata I/Os of gfs2, A REQ_PRIO flag on the metadata bio
      would be very informative to block layer code. For example, if bcache is
      used as a I/O cache for gfs2, it will be possible for bcache code to get
      the hint and cache the pre-fetched metadata blocks on cache device. This
      behavior may be helpful to improve metadata I/O performance if the
      following requests hit the cache.
      
      Here are the locations in gfs2 code where a REQ_PRIO flag should be added,
      - All places where REQ_READAHEAD is used, gfs2 code uses this flag for
        metadata read ahead.
      - In gfs2_meta_rq() where the first metadata block is read in.
      - In gfs2_write_buf_to_page(), read in quota metadata blocks to have them
        up to date.
      These metadata blocks are probably to be accessed again in future, adding
      a REQ_PRIO flag may have bcache to keep such metadata in fast cache
      device. For system without a cache layer, REQ_PRIO can still provide hint
      to block layer to handle metadata requests more properly.
      Signed-off-by: default avatarColy Li <colyli@suse.de>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      e477b24b
    • Wang Xibo's avatar
      GFS2: fix code parameter error in inode_go_lock · e7cb550d
      Wang Xibo authored
      In inode_go_lock() function, the parameter order of list_add() is error.
      According to the define of list_add(), the first parameter is new entry
      and the second is the list head, so ip->i_trunc_list should be the
      first parameter and the sdp->sd_trunc_list should be second.
      
      Signed-off-by: Wang Xibo<wang.xibo@zte.com.cn>
      Signed-off-by: Xiao Likun<xiao.likun@zte.com.cn>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      e7cb550d
  8. 19 Jul, 2017 2 commits
    • Andreas Gruenbacher's avatar
      gfs2: Fixup to "Get rid of flush_delayed_work in gfs2_evict_inode" · 98e5a91a
      Andreas Gruenbacher authored
      When commit 4fd1a579 moved the call to flush_delayed_work from
      gfs2_evict_inode to gfs2_inode_lookup to avoid calling into DLM during
      evict, a similar call should have been added to gfs2_create_inode:
      that's another code path in which glocks of previous inodes may be
      reused.
      
      The flush of the iopen glock work queue added by 4fd1a579, on the
      other hand, is unnecessary and can be removed.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      98e5a91a
    • Jan Kara's avatar
      gfs2: Don't clear SGID when inheriting ACLs · 914cea93
      Jan Kara authored
      When new directory 'DIR1' is created in a directory 'DIR0' with SGID bit
      set, DIR1 is expected to have SGID bit set (and owning group equal to
      the owning group of 'DIR0'). However when 'DIR0' also has some default
      ACLs that 'DIR1' inherits, setting these ACLs will result in SGID bit on
      'DIR1' to get cleared if user is not member of the owning group.
      
      Fix the problem by moving posix_acl_update_mode() out of
      __gfs2_set_acl() into gfs2_set_acl(). That way the function will not be
      called when inheriting ACLs which is what we want as it prevents SGID
      bit clearing and the mode has been properly set by posix_acl_create()
      anyway.
      
      Fixes: 07393101Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      914cea93
  9. 17 Jul, 2017 2 commits
    • Andreas Gruenbacher's avatar
      gfs2: Lock holder cleanup (fixup) · 283c9a97
      Andreas Gruenbacher authored
      Function gfs2_holder_initialized should be used in do_flock as well.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      283c9a97
    • Bob Peterson's avatar
      GFS2: Prevent double brelse in gfs2_meta_indirect_buffer · 61eaadcd
      Bob Peterson authored
      Before this patch, problems reading in indirect buffers would send
      an IO error back to the caller, and release the buffer_head with
      brelse() in function gfs2_meta_indirect_buffer, however, it would
      still return the address of the buffer_head it released. After the
      error was discovered, function gfs2_block_map would call function
      release_metapath to free all buffers. That checked:
      if (mp->mp_bh[i] == NULL) but since the value was set after the
      error, it was non-zero, so brelse was called a second time. This
      resulted in the following error:
      
      kernel: WARNING: at fs/buffer.c:1224 __brelse+0x3a/0x40() (Tainted: G        W  -- ------------   )
      kernel: Hardware name: RHEV Hypervisor
      kernel: VFS: brelse: Trying to free free buffer
      
      This patch changes gfs2_meta_indirect_buffer so it only sets
      the buffer_head pointer in cases where it isn't released.
      Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
      Acked-by: default avatarSteven Whitehouse <swhiteho@redhat.com>
      61eaadcd
  10. 08 Jul, 2017 6 commits
    • Kees Cook's avatar
      exec: Limit arg stack to at most 75% of _STK_LIM · da029c11
      Kees Cook authored
      To avoid pathological stack usage or the need to special-case setuid
      execs, just limit all arg stack usage to at most 75% of _STK_LIM (6MB).
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      da029c11
    • Linus Torvalds's avatar
      Merge tag 'for-linus-v4.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux · 088737f4
      Linus Torvalds authored
      Pull Writeback error handling updates from Jeff Layton:
       "This pile represents the bulk of the writeback error handling fixes
        that I have for this cycle. Some of the earlier patches in this pile
        may look trivial but they are prerequisites for later patches in the
        series.
      
        The aim of this set is to improve how we track and report writeback
        errors to userland. Most applications that care about data integrity
        will periodically call fsync/fdatasync/msync to ensure that their
        writes have made it to the backing store.
      
        For a very long time, we have tracked writeback errors using two flags
        in the address_space: AS_EIO and AS_ENOSPC. Those flags are set when a
        writeback error occurs (via mapping_set_error) and are cleared as a
        side-effect of filemap_check_errors (as you noted yesterday). This
        model really sucks for userland.
      
        Only the first task to call fsync (or msync or fdatasync) will see the
        error. Any subsequent task calling fsync on a file will get back 0
        (unless another writeback error occurs in the interim). If I have
        several tasks writing to a file and calling fsync to ensure that their
        writes got stored, then I need to have them coordinate with one
        another. That's difficult enough, but in a world of containerized
        setups that coordination may even not be possible.
      
        But wait...it gets worse!
      
        The calls to filemap_check_errors can be buried pretty far down in the
        call stack, and there are internal callers of filemap_write_and_wait
        and the like that also end up clearing those errors. Many of those
        callers ignore the error return from that function or return it to
        userland at nonsensical times (e.g. truncate() or stat()). If I get
        back -EIO on a truncate, there is no reason to think that it was
        because some previous writeback failed, and a subsequent fsync() will
        (incorrectly) return 0.
      
        This pile aims to do three things:
      
         1) ensure that when a writeback error occurs that that error will be
            reported to userland on a subsequent fsync/fdatasync/msync call,
            regardless of what internal callers are doing
      
         2) report writeback errors on all file descriptions that were open at
            the time that the error occurred. This is a user-visible change,
            but I think most applications are written to assume this behavior
            anyway. Those that aren't are unlikely to be hurt by it.
      
         3) document what filesystems should do when there is a writeback
            error. Today, there is very little consistency between them, and a
            lot of cargo-cult copying. We need to make it very clear what
            filesystems should do in this situation.
      
        To achieve this, the set adds a new data type (errseq_t) and then
        builds new writeback error tracking infrastructure around that. Once
        all of that is in place, we change the filesystems to use the new
        infrastructure for reporting wb errors to userland.
      
        Note that this is just the initial foray into cleaning up this mess.
        There is a lot of work remaining here:
      
         1) convert the rest of the filesystems in a similar fashion. Once the
            initial set is in, then I think most other fs' will be fairly
            simple to convert. Hopefully most of those can in via individual
            filesystem trees.
      
         2) convert internal waiters on writeback to use errseq_t for
            detecting errors instead of relying on the AS_* flags. I have some
            draft patches for this for ext4, but they are not quite ready for
            prime time yet.
      
        This was a discussion topic this year at LSF/MM too. If you're
        interested in the gory details, LWN has some good articles about this:
      
            https://lwn.net/Articles/718734/
            https://lwn.net/Articles/724307/"
      
      * tag 'for-linus-v4.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux:
        btrfs: minimal conversion to errseq_t writeback error reporting on fsync
        xfs: minimal conversion to errseq_t writeback error reporting
        ext4: use errseq_t based error handling for reporting data writeback errors
        fs: convert __generic_file_fsync to use errseq_t based reporting
        block: convert to errseq_t based writeback error tracking
        dax: set errors in mapping when writeback fails
        Documentation: flesh out the section in vfs.txt on storing and reporting writeback errors
        mm: set both AS_EIO/AS_ENOSPC and errseq_t in mapping_set_error
        fs: new infrastructure for writeback error handling and reporting
        lib: add errseq_t type and infrastructure for handling it
        mm: don't TestClearPageError in __filemap_fdatawait_range
        mm: clear AS_EIO/AS_ENOSPC when writeback initiation fails
        jbd2: don't clear and reset errors after waiting on writeback
        buffer: set errors in mapping at the time that the error occurs
        fs: check for writeback errors after syncing out buffers in generic_file_fsync
        buffer: use mapping_set_error instead of setting the flag
        mm: fix mapping_set_error call in me_pagecache_dirty
      088737f4
    • Linus Torvalds's avatar
      Merge tag 'for-linus-v4.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux · 33198c16
      Linus Torvalds authored
      Pull Writeback error handling fixes from Jeff Layton:
       "The main rationale for all of these changes is to tighten up writeback
        error reporting to userland. There are many ways now that writeback
        errors can be lost, such that fsync/fdatasync/msync return 0 when
        writeback actually failed.
      
        This pile contains a small set of cleanups and writeback error
        handling fixes that I was able to break off from the main pile (#2).
      
        Two of the patches in this pile are trivial. The exceptions are the
        patch to fix up error handling in write_one_page, and the patch to
        make JFS pay attention to write_one_page errors"
      
      * tag 'for-linus-v4.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux:
        fs: remove call_fsync helper function
        mm: clean up error handling in write_one_page
        JFS: do not ignore return code from write_one_page()
        mm: drop "wait" parameter from write_one_page()
      33198c16
    • Linus Torvalds's avatar
      Merge tag 'cifs-bug-fixes-for-4.13' of git://git.samba.org/sfrench/cifs-2.6 · 3ea4fcc5
      Linus Torvalds authored
      Pull cifs fixes from Steve French:
       "First set of CIFS/SMB3 fixes for the merge window. Also improves POSIX
        character mapping for SMB3"
      
      * tag 'cifs-bug-fixes-for-4.13' of git://git.samba.org/sfrench/cifs-2.6:
        CIFS: fix circular locking dependency
        cifs: set oparms.create_options rather than or'ing in CREATE_OPEN_BACKUP_INTENT
        cifs: Do not modify mid entry after submitting I/O in cifs_call_async
        CIFS: add SFM mapping for 0x01-0x1F
        cifs: hide unused functions
        cifs: Use smb 2 - 3 and cifsacl mount options getacl functions
        cifs: prototype declaration and definition for smb 2 - 3 and cifsacl mount options
        CIFS: add CONFIG_CIFS_DEBUG_KEYS to dump encryption keys
        cifs: set mapping error when page writeback fails in writepage or launder_pages
        SMB3: Enable encryption for SMB3.1.1
      3ea4fcc5
    • Linus Torvalds's avatar
      Merge tag 'gfs2-4.13.fixes.addendum' of... · 1a86fc75
      Linus Torvalds authored
      Merge tag 'gfs2-4.13.fixes.addendum' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2
      
      Pull GFS2 fix from Bob Peterson:
       "Sorry for the additional merge request, but Andreas discovered this
        problem soon after you processed our last gfs2 merge.
      
        This fixes a regression introduced by a patch we did in mid-2015
        (commit 88ffbf3e: "GFS2: Use resizable hash table for glocks"), so
        best to get it fixed. Some code was reverted that should not have
        been.
      
        The patch from Andreas Gruenbacher just re-adds code that had been
        there originally"
      
      * tag 'gfs2-4.13.fixes.addendum' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2:
        gfs2: Fix glock rhashtable rcu bug
      1a86fc75
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security · a7d40268
      Linus Torvalds authored
      Pull security layer fixes from James Morris:
       "Bugfixes for TPM and SELinux"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
        IB/core: Fix static analysis warning in ib_policy_change_task
        IB/core: Fix uninitialized variable use in check_qp_port_pkey_settings
        tpm: do not suspend/resume if power stays on
        tpm: use tpm2_pcr_read() in tpm2_do_selftest()
        tpm: use tpm_buf functions in tpm2_pcr_read()
        tpm_tis: make ilb_base_addr static
        tpm: consolidate the TPM startup code
        tpm: Enable CLKRUN protocol for Braswell systems
        tpm/tpm_crb: fix priv->cmd_size initialisation
        tpm: fix a kernel memory leak in tpm-sysfs.c
        tpm: Issue a TPM2_Shutdown for TPM2 devices.
        Add "shutdown" to "struct class".
      a7d40268
  11. 07 Jul, 2017 5 commits
    • Linus Torvalds's avatar
      Merge tag 'kbuild-thinar-v4.13' of... · 98ced886
      Linus Torvalds authored
      Merge tag 'kbuild-thinar-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
      
      Pull Kbuild thin archives updates from Masahiro Yamada:
       "Thin archives migration by Nicholas Piggin.
      
        THIN_ARCHIVES has been available for a while as an optional feature
        only for PowerPC architecture, but we do not need two different
        intermediate-artifact schemes.
      
        Using thin archives instead of conventional incremental linking has
        various advantages:
      
         - save disk space for builds
      
         - speed-up building a little
      
         - fix some link issues (for example, allyesconfig on ARM) due to more
           flexibility for the final linking
      
         - work better with dead code elimination we are planning
      
        As discussed before, this migration has been done unconditionally so
        that any problems caused by this will show up with "git bisect".
      
        With testing with 0-day and linux-next, some architectures actually
        showed up problems, but they were trivial and all fixed now"
      
      * tag 'kbuild-thinar-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        tile: remove unneeded extra-y in Makefile
        kbuild: thin archives make default for all archs
        x86/um: thin archives build fix
        tile: thin archives fix linking
        ia64: thin archives fix linking
        sh: thin archives fix linking
        kbuild: handle libs-y archives separately from built-in.o archives
        kbuild: thin archives use P option to ar
        kbuild: thin archives final link close --whole-archives option
        ia64: remove unneeded extra-y in Makefile.gate
        tile: fix dependency and .*.cmd inclusion for incremental build
        sparc64: Use indirect calls in hamming weight stubs
      98ced886
    • Linus Torvalds's avatar
      Merge tag 'kbuild-misc-v4.13' of... · 16ffc4c3
      Linus Torvalds authored
      Merge tag 'kbuild-misc-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
      
      Pull misc Kbuild updates from Masahiro Yamada:
      
       - Use more portable shebang for Perl scripts
      
       - Remove trailing spaces from GCC version in kernel log
      
       - Make initramfs generation deterministic
      
      * tag 'kbuild-misc-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        kbuild: create deterministic initramfs directory listings
        scripts/mkcompile_h: Remove trailing spaces from compiler version
        scripts: Switch to more portable Perl shebang
      16ffc4c3
    • Linus Torvalds's avatar
      Merge tag 'kbuild-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild · 58f051fc
      Linus Torvalds authored
      Pull Kbuild updates from Masahiro Yamada:
      
       - Clean up Makefiles and scripts
      
       - Improve clang support
      
       - Remove unneeded genhdr-y syntax
      
       - Remove unneeded cc-option-align macro
      
       - Introduce __cc-option macro and use it to fix x86 boot code compiler
         flags
      
      * tag 'kbuild-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        kbuild: improve comments on KBUILD_SRC
        x86/build: Specify stack alignment for clang
        x86/build: Use __cc-option for boot code compiler options
        kbuild: Add __cc-option macro
        kbuild: remove cc-option-align
        kbuild: replace genhdr-y with generated-y
        kbuild: clang: Disable 'address-of-packed-member' warning
        kbuild: remove duplicated arch/*/include/generated/uapi include path
        kbuild: speed up checksyscalls.sh
        kbuild: simplify silent build (-s) detection
      58f051fc
    • Linus Torvalds's avatar
      Merge tag 'linux-kselftest-4.13-rc1-update' of... · ef3ad089
      Linus Torvalds authored
      Merge tag 'linux-kselftest-4.13-rc1-update' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest
      
      Pull Kselftest updates from Shuah Khan:
       "This update consists of:
      
         - TAP13 framework and changes to some tests to convert to TAP13.
           Converting kselftest output to standard format will help identify
           run to run differences and pin point failures easily. TAP13 format
           has been in use for several years and the output is human friendly.
      
           Please find the specification:
             https://testanything.org/tap-version-13-specification.html
      
           Credit goes to Tim Bird for recommending TAP13 as a suitable
           format, and to Grag KH for kick starting the work with help from
           Paul Elder and Alice Ferrazzi
      
           The first phase of the TAp13 conversion is included in this update.
           Future updates will include updates to rest of the tests.
      
         - Masami Hiramatsu fixed ftrace to run on 4.9 stable kernels.
      
         - Kselftest documnetation has been converted to ReST format. Document
           now has a new home under Documentation/dev-tools.
      
         - kselftest_harness.h is now available for general use as a result of
           Mickaël Salaün's work.
      
         - Several fixes to skip and/or fail tests gracefully on older
           releases"
      
      * tag 'linux-kselftest-4.13-rc1-update' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest: (48 commits)
        selftests: membarrier: use ksft_* var arg msg api
        selftests: breakpoints: breakpoint_test_arm64: convert test to use TAP13
        selftests: breakpoints: step_after_suspend_test use ksft_* var arg msg api
        selftests: breakpoint_test: use ksft_* var arg msg api
        kselftest: add ksft_print_msg() function to output general information
        kselftest: make ksft_* output functions variadic
        selftests/capabilities: Fix the test_execve test
        selftests: intel_pstate: add .gitignore
        selftests: fix memory-hotplug test
        selftests: add missing test name in memory-hotplug test
        selftests: check percentage range for memory-hotplug test
        selftests: check hot-pluggagble memory for memory-hotplug test
        selftests: typo correction for memory-hotplug test
        selftests: ftrace: Use md5sum to take less time of checking logs
        tools/testing/selftests/sysctl: Add pre-check to the value of writes_strict
        kselftest.rst: do some adjustments after ReST conversion
        selftest/net/Makefile: Specify output with $(OUTPUT)
        selftest/intel_pstate/aperf: Use LDLIBS instead of LDFLAGS
        selftest/memfd/Makefile: Fix build error
        selftests: lib: Skip tests on missing test modules
        ...
      ef3ad089
    • Linus Torvalds's avatar
      Merge tag 'openrisc-for-linus' of git://github.com/openrisc/linux · 37949075
      Linus Torvalds authored
      Pull OpenRISC updates from Stafford Horne:
       "Openrisc fixes for this 4.13 merge window, there is not really much
        here:
      
         - include cleanups, one with should reduce build time slightly
      
         - switch to new toolchain to new (>2 year old) toolchain prefix"
      
      * tag 'openrisc-for-linus' of git://github.com/openrisc/linux:
        openrisc: defconfig: Cleanup from old Kconfig options
        openrisc: explicitly include linux/bug.h in asm/fixmap.h
        openrisc: Switch to use export.h instead of module.h
        openrisc: Change toolchain from or32- to or1k-
      37949075