1. 16 7月, 2019 2 次提交
  2. 15 7月, 2019 3 次提交
  3. 14 7月, 2019 1 次提交
  4. 13 7月, 2019 11 次提交
    • E
      ppp: mppe: Revert "ppp: mppe: Add softdep to arc4" · 25a09ce7
      Eric Biggers 提交于
      Commit 0e5a610b ("ppp: mppe: switch to RC4 library interface"),
      which was merged through the crypto tree for v5.3, changed ppp_mppe.c to
      use the new arc4_crypt() library function rather than access RC4 through
      the dynamic crypto_skcipher API.
      
      Meanwhile commit aad1dcc4 ("ppp: mppe: Add softdep to arc4") was
      merged through the net tree and added a module soft-dependency on "arc4".
      
      The latter commit no longer makes sense because the code now uses the
      "libarc4" module rather than "arc4", and also due to the direct use of
      arc4_crypt(), no module soft-dependency is required.
      
      So revert the latter commit.
      
      Cc: Takashi Iwai <tiwai@suse.de>
      Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
      Signed-off-by: NEric Biggers <ebiggers@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      25a09ce7
    • C
      net: dsa: qca8k: replace legacy gpio include · f32ae8a5
      Christian Lamparter 提交于
      This patch replaces the legacy bulk gpio.h include
      with the proper gpio/consumer.h variant. This was
      caught by the kbuild test robot that was running
      into an error because of this.
      
      For more information why linux/gpio.h is bad can be found in:
      commit 56a46b61 ("gpio: Clarify that <linux/gpio.h> is legacy")
      Reported-by: Nkbuild test robot <lkp@intel.com>
      Link: https://www.spinics.net/lists/netdev/msg584447.html
      Fixes: a653f2f5 ("net: dsa: qca8k: introduce reset via gpio feature")
      Signed-off-by: NChristian Lamparter <chunkeey@gmail.com>
      Reviewed-by: NVivien Didelot <vivien.didelot@gmail.com>
      Reviewed-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f32ae8a5
    • J
      net: hisilicon: Use devm_platform_ioremap_resource · 56170ba3
      Jiangfeng Xiao 提交于
      Use devm_platform_ioremap_resource instead of
      devm_ioremap_resource. Make the code simpler.
      Signed-off-by: NJiangfeng Xiao <xiaojiangfeng@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      56170ba3
    • A
      cxgb4: reduce kernel stack usage in cudbg_collect_mem_region() · 752c2ea2
      Arnd Bergmann 提交于
      The cudbg_collect_mem_region() and cudbg_read_fw_mem() both use several
      hundred kilobytes of kernel stack space. One gets inlined into the other,
      which causes the stack usage to be combined beyond the warning limit
      when building with clang:
      
      drivers/net/ethernet/chelsio/cxgb4/cudbg_lib.c:1057:12: error: stack frame size of 1244 bytes in function 'cudbg_collect_mem_region' [-Werror,-Wframe-larger-than=]
      
      Restructuring cudbg_collect_mem_region() lets clang do the same
      optimization that gcc does and reuse the stack slots as it can
      see that the large variables are never used together.
      
      A better fix might be to avoid using cudbg_meminfo on the stack
      altogether, but that requires a larger rewrite.
      
      Fixes: a1c69520 ("cxgb4: collect MC memory dump")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      752c2ea2
    • J
      nfp: flower: ensure ip protocol is specified for L4 matches · 103b7c25
      John Hurley 提交于
      Flower rules on the NFP firmware are able to match on an IP protocol
      field. When parsing rules in the driver, unknown IP protocols are only
      rejected when further matches are to be carried out on layer 4 fields, as
      the firmware will not be able to extract such fields from packets.
      
      L4 protocol dissectors such as FLOW_DISSECTOR_KEY_PORTS are only parsed if
      an IP protocol is specified. This leaves a loophole whereby a rule that
      attempts to match on transport layer information such as port numbers but
      does not explicitly give an IP protocol type can be incorrectly offloaded
      (in this case with wildcard port numbers matches).
      
      Fix this by rejecting the offload of flows that attempt to match on L4
      information, not only when matching on an unknown IP protocol type, but
      also when the protocol is wildcarded.
      
      Fixes: 2a047845 ("nfp: flower: check L4 matches on unknown IP protocols")
      Signed-off-by: NJohn Hurley <john.hurley@netronome.com>
      Reviewed-by: NJakub Kicinski <jakub.kicinski@netronome.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      103b7c25
    • J
      nfp: flower: fix ethernet check on match fields · fd262a6d
      John Hurley 提交于
      NFP firmware does not explicitly match on an ethernet type field. Rather,
      each rule has a bitmask of match fields that can be used to infer the
      ethernet type.
      
      Currently, if a flower rule contains an unknown ethernet type, a check is
      carried out for matches on other fields of the packet. If matches on
      layer 3 or 4 are found, then the offload is rejected as firmware will not
      be able to extract these fields from a packet with an ethernet type it
      does not currently understand.
      
      However, if a rule contains an unknown ethernet type without any L3 (or
      above) matches then this will effectively be offloaded as a rule with a
      wildcarded ethertype. This can lead to misclassifications on the firmware.
      
      Fix this issue by rejecting all flower rules that specify a match on an
      unknown ethernet type.
      
      Further ensure correct offloads by moving the 'L3 and above' check to any
      rule that does not specify an ethernet type and rejecting rules with
      further matches. This means that we can still offload rules with a
      wildcarded ethertype if they only match on L2 fields but will prevent
      rules which match on further fields that we cannot be sure if the firmware
      will be able to extract.
      
      Fixes: af9d842c ("nfp: extend flower add flow offload")
      Signed-off-by: NJohn Hurley <john.hurley@netronome.com>
      Reviewed-by: NJakub Kicinski <jakub.kicinski@netronome.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fd262a6d
    • V
      net/mlx5e: Provide cb_list pointer when setting up tc block on rep · 3929502b
      Vlad Buslov 提交于
      Recent refactoring of tc block offloads infrastructure introduced new
      flow_block_cb_setup_simple() method intended to be used as unified way for
      all drivers to register offload callbacks. However, commit that actually
      extended all users (drivers) with block cb list and provided it to
      flow_block infra missed mlx5 en_rep. This leads to following NULL-pointer
      dereference when creating Qdisc:
      
      [  278.385175] BUG: kernel NULL pointer dereference, address: 0000000000000000
      [  278.393233] #PF: supervisor read access in kernel mode
      [  278.399446] #PF: error_code(0x0000) - not-present page
      [  278.405847] PGD 8000000850e73067 P4D 8000000850e73067 PUD 8620cd067 PMD 0
      [  278.414141] Oops: 0000 [#1] SMP PTI
      [  278.419019] CPU: 7 PID: 3369 Comm: tc Not tainted 5.2.0-rc6+ #492
      [  278.426580] Hardware name: Supermicro SYS-2028TP-DECR/X10DRT-P, BIOS 2.0b 03/30/2017
      [  278.435853] RIP: 0010:flow_block_cb_setup_simple+0xc4/0x190
      [  278.442953] Code: 10 48 89 42 08 48 89 10 48 b8 00 01 00 00 00 00 ad de 49 89 00 48 05 00 01 00 00 49 89 40 08 31 c0 c3 b8 a1 ff ff ff c3 f3 c3 <48> 8b 06 48 39 c6 75 0a eb 1a 48 8b 00 48 39 c6 74 12
       48 3b 50 28
      [  278.464829] RSP: 0018:ffffaf07c3f97990 EFLAGS: 00010246
      [  278.471648] RAX: 0000000000000000 RBX: ffff9b43ed4c7680 RCX: ffff9b43d5f80840
      [  278.480408] RDX: ffffffffc0491650 RSI: 0000000000000000 RDI: ffffaf07c3f97998
      [  278.489110] RBP: ffff9b43ddff9000 R08: ffff9b43d5f80840 R09: 0000000000000001
      [  278.497838] R10: 0000000000000009 R11: 00000000000003ad R12: ffffaf07c3f97c08
      [  278.506595] R13: ffff9b43d5f80000 R14: ffff9b43ed4c7680 R15: ffff9b43dfa20b40
      [  278.515374] FS:  00007f796be1b400(0000) GS:ffff9b43ef840000(0000) knlGS:0000000000000000
      [  278.525099] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [  278.532453] CR2: 0000000000000000 CR3: 0000000840398002 CR4: 00000000001606e0
      [  278.541197] Call Trace:
      [  278.545252]  tcf_block_offload_cmd.isra.52+0x7e/0xb0
      [  278.551871]  tcf_block_get_ext+0x365/0x3e0
      [  278.557569]  qdisc_create+0x15c/0x4e0
      [  278.562859]  ? kmem_cache_alloc_trace+0x1a2/0x1c0
      [  278.569235]  tc_modify_qdisc+0x1c8/0x780
      [  278.574761]  rtnetlink_rcv_msg+0x291/0x340
      [  278.580518]  ? _cond_resched+0x15/0x40
      [  278.585856]  ? rtnl_calcit.isra.29+0x120/0x120
      [  278.591868]  netlink_rcv_skb+0x4a/0x110
      [  278.597198]  netlink_unicast+0x1a0/0x250
      [  278.602601]  netlink_sendmsg+0x2c1/0x3c0
      [  278.608022]  sock_sendmsg+0x5b/0x60
      [  278.612969]  ___sys_sendmsg+0x289/0x310
      [  278.618231]  ? do_wp_page+0x99/0x730
      [  278.623216]  ? page_add_new_anon_rmap+0xbe/0x140
      [  278.629298]  ? __handle_mm_fault+0xc84/0x1360
      [  278.635113]  ? __sys_sendmsg+0x5e/0xa0
      [  278.640285]  __sys_sendmsg+0x5e/0xa0
      [  278.645239]  do_syscall_64+0x5b/0x1b0
      [  278.650274]  entry_SYSCALL_64_after_hwframe+0x44/0xa9
      [  278.656697] RIP: 0033:0x7f796abdeb87
      [  278.661628] Code: 64 89 02 48 c7 c0 ff ff ff ff eb b9 0f 1f 80 00 00 00 00 8b 05 6a 2b 2c 00 48 63 d2 48 63 ff 85 c0 75 18 b8 2e 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 59 f3 c3 0f 1f 80 00 00 00 00 53
       48 89 f3 48
      [  278.683248] RSP: 002b:00007ffde213ba48 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
      [  278.692245] RAX: ffffffffffffffda RBX: 000000005d261e6f RCX: 00007f796abdeb87
      [  278.700862] RDX: 0000000000000000 RSI: 00007ffde213bab0 RDI: 0000000000000003
      [  278.709527] RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000006
      [  278.718167] R10: 000000000000000c R11: 0000000000000246 R12: 0000000000000001
      [  278.726743] R13: 000000000067b580 R14: 0000000000000000 R15: 0000000000000000
      [  278.735302] Modules linked in: dummy vxlan ip6_udp_tunnel udp_tunnel sch_ingress nfsv3 nfs_acl nfs lockd grace fscache bridge stp llc sunrpc mlx5_ib ib_uverbs intel_rapl ib_core sb_edac x86_pkg_temp_
      thermal intel_powerclamp coretemp kvm_intel kvm mlx5_core irqbypass crct10dif_pclmul crc32_pclmul crc32c_intel igb ghash_clmulni_intel ses mei_me enclosure mlxfw ipmi_ssif intel_cstate iTCO_wdt ptp mei
      pps_core iTCO_vendor_support pcspkr joydev intel_uncore i2c_i801 ipmi_si lpc_ich intel_rapl_perf ioatdma wmi dca pcc_cpufreq ipmi_devintf ipmi_msghandler acpi_power_meter acpi_pad ast i2c_algo_bit drm_k
      ms_helper ttm drm mpt3sas raid_class scsi_transport_sas
      [  278.802263] CR2: 0000000000000000
      [  278.807170] ---[ end trace b1f0a442a279e66f ]---
      
      Extend en_rep with new static mlx5e_rep_block_cb_list list and pass it to
      flow_block_cb_setup_simple() function instead of hardcoded NULL pointer.
      
      Fixes: 955bcb6e ("drivers: net: use flow block API")
      Signed-off-by: NVlad Buslov <vladbu@mellanox.com>
      Acked-by: NPablo Neira Ayuso <pablo@netfilter.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3929502b
    • D
      net: phy: make exported variables non-static · 54638c6e
      Denis Efremov 提交于
      The variables phy_basic_ports_array, phy_fibre_port_array and
      phy_all_ports_features_array are declared static and marked
      EXPORT_SYMBOL_GPL(), which is at best an odd combination.
      Because the variables were decided to be a part of API, this commit
      removes the static attributes and adds the declarations to the header.
      
      Fixes: 3c1bcc86 ("net: ethernet: Convert phydev advertize and supported from u32 to link mode")
      Signed-off-by: NDenis Efremov <efremov@linux.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      54638c6e
    • A
      davinci_cpdma: don't cast dma_addr_t to pointer · c653f61a
      Arnd Bergmann 提交于
      dma_addr_t may be 64-bit wide on 32-bit architectures, so it is not
      valid to cast between it and a pointer:
      
      drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit_si':
      drivers/net/ethernet/ti/davinci_cpdma.c:1047:12: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
      drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_idle_submit_mapped':
      drivers/net/ethernet/ti/davinci_cpdma.c:1114:12: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
      drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit_mapped':
      drivers/net/ethernet/ti/davinci_cpdma.c:1164:12: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
      
      Solve this by using two separate members in 'struct submit_info'.
      Since this avoids the use of the 'flag' member, the structure does
      not even grow in typical configurations.
      
      Fixes: 6670acac ("net: ethernet: ti: davinci_cpdma: add dma mapped submit")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Reviewed-by: NIvan Khoronzhuk <ivan.khoronzhuk@linaro.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c653f61a
    • N
      net/mlx5e: Convert single case statement switch statements into if statements · 9db7e618
      Nathan Chancellor 提交于
      During the review of commit 1ff2f0fa ("net/mlx5e: Return in default
      case statement in tx_post_resync_params"), Leon and Nick pointed out
      that the switch statements can be converted to single if statements
      that return early so that the code is easier to follow.
      Suggested-by: NLeon Romanovsky <leon@kernel.org>
      Suggested-by: NNick Desaulniers <ndesaulniers@google.com>
      Signed-off-by: NNathan Chancellor <natechancellor@gmail.com>
      Reviewed-by: NLeon Romanovsky <leonro@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9db7e618
    • P
      scripts/spelling.txt: drop "sepc" from the misspelling list · cc0e5f1c
      Paul Walmsley 提交于
      The RISC-V architecture has a register named the "Supervisor Exception
      Program Counter", or "sepc".  This abbreviation triggers checkpatch.pl's
      misspelling detector, resulting in noise in the checkpatch output.  The
      risk that this noise could cause more useful warnings to be missed seems
      to outweigh the harm of an occasional misspelling of "spec".  Thus drop
      the "sepc" entry from the misspelling list.
      
      [akpm@linux-foundation.org: fix existing "sepc" instances, per Joe]
      Link: http://lkml.kernel.org/r/20190518210037.13674-1-paul.walmsley@sifive.comSigned-off-by: NPaul Walmsley <paul.walmsley@sifive.com>
      Cc: Joe Perches <joe@perches.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      cc0e5f1c
  5. 12 7月, 2019 11 次提交
  6. 10 7月, 2019 12 次提交