1. 23 9月, 2019 1 次提交
  2. 18 9月, 2019 1 次提交
  3. 17 9月, 2019 3 次提交
    • B
      mailbox: mediatek: cmdq: clear the event in cmdq initial flow · 6058f118
      Bibby Hsieh 提交于
      GCE hardware stored event information in own internal sysram,
      if the initial value in those sysram is not zero value
      it will cause a situation that gce can wait the event immediately
      after client ask gce to wait event but not really trigger the
      corresponding hardware.
      
      In order to make sure that the wait event function is
      exactly correct, we need to clear the sysram value in
      cmdq initial flow.
      
      Fixes: 623a6143 ("mailbox: mediatek: Add Mediatek CMDQ driver")
      Signed-off-by: NBibby Hsieh <bibby.hsieh@mediatek.com>
      Reviewed-by: NCK Hu <ck.hu@mediatek.com>
      Reviewed-by: NMatthias Brugger <matthias.bgg@gmail.com>
      Signed-off-by: NJassi Brar <jaswinder.singh@linaro.org>
      6058f118
    • V
      taprio: Add support for hardware offloading · 9c66d156
      Vinicius Costa Gomes 提交于
      This allows taprio to offload the schedule enforcement to capable
      network cards, resulting in more precise windows and less CPU usage.
      
      The gate mask acts on traffic classes (groups of queues of same
      priority), as specified in IEEE 802.1Q-2018, and following the existing
      taprio and mqprio semantics.
      It is up to the driver to perform conversion between tc and individual
      netdev queues if for some reason it needs to make that distinction.
      
      Full offload is requested from the network interface by specifying
      "flags 2" in the tc qdisc creation command, which in turn corresponds to
      the TCA_TAPRIO_ATTR_FLAG_FULL_OFFLOAD bit.
      
      The important detail here is the clockid which is implicitly /dev/ptpN
      for full offload, and hence not configurable.
      
      A reference counting API is added to support the use case where Ethernet
      drivers need to keep the taprio offload structure locally (i.e. they are
      a multi-port switch driver, and configuring a port depends on the
      settings of other ports as well). The refcount_t variable is kept in a
      private structure (__tc_taprio_qopt_offload) and not exposed to drivers.
      
      In the future, the private structure might also be expanded with a
      backpointer to taprio_sched *q, to implement the notification system
      described in the patch (of when admin became oper, or an error occurred,
      etc, so the offload can be monitored with 'tc qdisc show').
      Signed-off-by: NVinicius Costa Gomes <vinicius.gomes@intel.com>
      Signed-off-by: NVoon Weifeng <weifeng.voon@intel.com>
      Signed-off-by: NVladimir Oltean <olteanv@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9c66d156
    • P
      cifs: Add support for root file systems · 8eecd1c2
      Paulo Alcantara (SUSE) 提交于
      Introduce a new CONFIG_CIFS_ROOT option to handle root file systems
      over a SMB share.
      
      In order to mount the root file system during the init process, make
      cifs.ko perform non-blocking socket operations while mounting and
      accessing it.
      
      Cc: Steve French <smfrench@gmail.com>
      Reviewed-by: NAurelien Aptel <aaptel@suse.com>
      Signed-off-by: NPaulo Alcantara (SUSE) <paulo@paulo.ac>
      Signed-off-by: NSteve French <stfrench@microsoft.com>
      8eecd1c2
  4. 16 9月, 2019 5 次提交
    • T
      tcp: Add TCP_INFO counter for packets received out-of-order · f9af2dbb
      Thomas Higdon 提交于
      For receive-heavy cases on the server-side, we want to track the
      connection quality for individual client IPs. This counter, similar to
      the existing system-wide TCPOFOQueue counter in /proc/net/netstat,
      tracks out-of-order packet reception. By providing this counter in
      TCP_INFO, it will allow understanding to what degree receive-heavy
      sockets are experiencing out-of-order delivery and packet drops
      indicating congestion.
      
      Please note that this is similar to the counter in NetBSD TCP_INFO, and
      has the same name.
      
      Also note that we avoid increasing the size of the tcp_sock struct by
      taking advantage of a hole.
      Signed-off-by: NThomas Higdon <tph@fb.com>
      Acked-by: NNeal Cardwell <ncardwell@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f9af2dbb
    • I
      bpf: fix accessing bpf_sysctl.file_pos on s390 · d895a0f1
      Ilya Leoshkevich 提交于
      "ctx:file_pos sysctl:read write ok" fails on s390 with "Read value  !=
      nux". This is because verifier rewrites a complete 32-bit
      bpf_sysctl.file_pos update to a partial update of the first 32 bits of
      64-bit *bpf_sysctl_kern.ppos, which is not correct on big-endian
      systems.
      
      Fix by using an offset on big-endian systems.
      
      Ditto for bpf_sysctl.file_pos reads. Currently the test does not detect
      a problem there, since it expects to see 0, which it gets with high
      probability in error cases, so change it to seek to offset 3 and expect
      3 in bpf_sysctl.file_pos.
      
      Fixes: e1550bfe ("bpf: Add file_pos field to bpf_sysctl ctx")
      Signed-off-by: NIlya Leoshkevich <iii@linux.ibm.com>
      Acked-by: NYonghong Song <yhs@fb.com>
      Signed-off-by: NDaniel Borkmann <daniel@iogearbox.net>
      Link: https://lore.kernel.org/bpf/20190816105300.49035-1-iii@linux.ibm.com/
      d895a0f1
    • H
      block: make rq sector size accessible for block stats · 3d244306
      Hou Tao 提交于
      Currently rq->data_len will be decreased by partial completion or
      zeroed by completion, so when blk_stat_add() is invoked, data_len
      will be zero and there will never be samples in poll_cb because
      blk_mq_poll_stats_bkt() will return -1 if data_len is zero.
      
      We could move blk_stat_add() back to __blk_mq_complete_request(),
      but that would make the effort of trying to call ktime_get_ns()
      once in vain. Instead we can reuse throtl_size field, and use
      it for both block stats and block throttle, and adjust the
      logic in blk_mq_poll_stats_bkt() accordingly.
      
      Fixes: 4bc6339a ("block: move blk_stat_add() to __blk_mq_end_request()")
      Tested-by: NPavel Begunkov <asml.silence@gmail.com>
      Signed-off-by: NHou Tao <houtao1@huawei.com>
      Signed-off-by: NJens Axboe <axboe@kernel.dk>
      3d244306
    • R
      compiler-types.h: add asm_inline definition · eb111869
      Rasmus Villemoes 提交于
      This adds an asm_inline macro which expands to "asm inline" [1] when
      the compiler supports it. This is currently gcc 9.1+, gcc 8.3
      and (once released) gcc 7.5 [2]. It expands to just "asm" for other
      compilers.
      
      Using asm inline("foo") instead of asm("foo") overrules gcc's
      heuristic estimate of the size of the code represented by the asm()
      statement, and makes gcc use the minimum possible size instead. That
      can in turn affect gcc's inlining decisions.
      
      I wasn't sure whether to make this a function-like macro or not - this
      way, it can be combined with volatile as
      
        asm_inline volatile()
      
      but perhaps we'd prefer to spell that
      
        asm_inline_volatile()
      
      anyway.
      
      The Kconfig logic is taken from an RFC patch by Masahiro Yamada [3].
      
      [1] Technically, asm __inline, since both inline and __inline__
      are macros that attach various attributes, making gcc barf if one
      literally does "asm inline()". However, the third spelling __inline is
      available for referring to the bare keyword.
      
      [2] https://lore.kernel.org/lkml/20190907001411.GG9749@gate.crashing.org/
      
      [3] https://lore.kernel.org/lkml/1544695154-15250-1-git-send-email-yamada.masahiro@socionext.com/Signed-off-by: NRasmus Villemoes <linux@rasmusvillemoes.dk>
      Signed-off-by: NMiguel Ojeda <miguel.ojeda.sandonis@gmail.com>
      eb111869
    • R
      compiler_types.h: don't #define __inline · c30724e9
      Rasmus Villemoes 提交于
      The spellings __inline and __inline__ should be reserved for uses
      where one really wants to refer to the inline keyword, regardless of
      whether or not the spelling "inline" has been #defined to something
      else. Due to use of __inline__ in uapi headers, we can't easily get
      rid of the definition of __inline__. However, almost all users of
      __inline have been converted to inline, so we can get rid of that
      #define.
      
      The exception is include/acpi/platform/acintel.h. However, that header
      is only included when using the intel compiler (does anybody actually
      build the kernel with that?), and the ACPI_INLINE macro is only used
      in the definition of utterly trivial stub functions, where I doubt a
      small change of semantics (lack of __gnu_inline) changes anything.
      Signed-off-by: NRasmus Villemoes <linux@rasmusvillemoes.dk>
      [Fix trivial typo in message]
      Signed-off-by: NMiguel Ojeda <miguel.ojeda.sandonis@gmail.com>
      c30724e9
  5. 14 9月, 2019 1 次提交
    • M
      export.h, genksyms: do not make genksyms calculate CRC of trimmed symbols · 69a94abb
      Masahiro Yamada 提交于
      Arnd Bergmann reported false-positive modpost warnings detected by his
      randconfig testing of linux-next.
      
      Actually, this happens under the combination of CONFIG_MODVERSIONS
      and CONFIG_TRIM_UNUSED_KSYMS since commit 15bfc234 ("modpost:
      check for static EXPORT_SYMBOL* functions").
      
      For example, arch/arm/config/multi_v7_defconfig + CONFIG_MODVERSIONS
      + CONFIG_TRIM_UNUSED_KSYMS produces the following false-positives:
      
      WARNING: "__lshrdi3" [vmlinux] is a static (unknown)
      WARNING: "__ashrdi3" [vmlinux] is a static (unknown)
      WARNING: "__aeabi_lasr" [vmlinux] is a static (unknown)
      WARNING: "__aeabi_llsr" [vmlinux] is a static (unknown)
      WARNING: "ftrace_set_clr_event" [vmlinux] is a static (unknown)
      WARNING: "__muldi3" [vmlinux] is a static (unknown)
      WARNING: "__aeabi_ulcmp" [vmlinux] is a static (unknown)
      WARNING: "__ucmpdi2" [vmlinux] is a static (unknown)
      WARNING: "__aeabi_lmul" [vmlinux] is a static (unknown)
      WARNING: "__bswapsi2" [vmlinux] is a static (unknown)
      WARNING: "__bswapdi2" [vmlinux] is a static (unknown)
      WARNING: "__ashldi3" [vmlinux] is a static (unknown)
      WARNING: "__aeabi_llsl" [vmlinux] is a static (unknown)
      
      The root cause of the problem is not in the modpost, but in the
      implementation of CONFIG_TRIM_UNUSED_KSYMS.
      
      If there is at least one untrimmed symbol in the file, genksyms is
      invoked to calculate CRC of *all* the exported symbols in that file
      even if some of them have been trimmed due to no caller existing.
      
      As a result, .tmp_*.ver files contain CRC of trimmed symbols, thus
      unneeded, orphan __crc* symbols are added to objects. It had been
      harmless until recently.
      
      With commit 15bfc234 ("modpost: check for static EXPORT_SYMBOL*
      functions"), it is now harmful because the bogus __crc* symbols make
      modpost call sym_update_crc() to add the symbols to the hash table,
      but there is no one that clears the ->is_static member.
      
      I gave Fixes to the first commit that uncovered the issue, but the
      potential problem has long existed since commit f2355416
      ("export.h: allow for per-symbol configurable EXPORT_SYMBOL()").
      
      Fixes: 15bfc234 ("modpost: check for static EXPORT_SYMBOL* functions")
      Reported-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NMasahiro Yamada <yamada.masahiro@socionext.com>
      Tested-by: NArnd Bergmann <arnd@arndb.de>
      69a94abb
  6. 13 9月, 2019 15 次提交
  7. 12 9月, 2019 5 次提交
  8. 11 9月, 2019 9 次提交