Re: Registering IRQ for MT7530 internal PHYs

2020-12-29 Thread Heiner Kallweit
On 30.12.2020 05:22, DENG Qingfang wrote: > Hi, > > I added MT7530 IRQ support and registered its internal PHYs to IRQ. > It works but my patch used two hacks. > > 1. Removed phy_drv_supports_irq check, because config_intr and > handle_interrupt are not set for Generic PHY. > I don't think that'

[PATCH] ibmvnic: fix: NULL pointer dereference.

2020-12-29 Thread YANG LI
The error is due to dereference a null pointer in function reset_one_sub_crq_queue(): if (!scrq) { netdev_dbg(adapter->netdev, "Invalid scrq reset. irq (%d) or msgs(%p).\n", scrq->irq, scrq->msgs); return -EINVAL; } If the expression is true, scr

Re: [PATCH] 9p: fix: Uninitialized variable p.

2020-12-29 Thread Dominique Martinet
YANG LI wrote on Wed, Dec 30, 2020: > The pointer p is being used but it isn't being initialized, > need to assign a NULL to it. My understanding is p has to be initialized: the only way out of the while(1) loop below sets it. I don't mind fixing false positive warnings as it makes maintenance e

Re: Re: [RFC v2 09/13] vduse: Add support for processing vhost iotlb message

2020-12-29 Thread Yongji Xie
On Wed, Dec 30, 2020 at 2:11 PM Jason Wang wrote: > > > On 2020/12/29 下午6:26, Yongji Xie wrote: > > On Tue, Dec 29, 2020 at 5:11 PM Jason Wang wrote: > >> > >> > >> - Original Message - > >>> On Mon, Dec 28, 2020 at 4:43 PM Jason Wang wrote: > > On 2020/12/28 下午4:14, Yongji Xie

Re: [PATCH 12/21] vhost-vdpa: introduce uAPI to get the number of virtqueue groups

2020-12-29 Thread Jason Wang
On 2020/12/29 下午8:24, Eli Cohen wrote: On Wed, Dec 16, 2020 at 02:48:09PM +0800, Jason Wang wrote: Follows the vDPA support for multiple address spaces, this patch introduce uAPI for the userspace to know the number of virtqueue groups supported by the vDPA device. Can you explain what exactl

Re: [PATCH] liquidio: fix: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'.

2020-12-29 Thread Joe Perches
On Wed, 2020-12-30 at 14:41 +0800, YANG LI wrote: > For safety, modify '%u' to '%d' to keep the type consistent. There is no additional safety here. The for loop ensures that i is positive as num_ioq_vector is also int and so i can not be negative as it's incremented from 0. > diff --git a/drive

[PATCH] 9p: fix: Uninitialized variable p.

2020-12-29 Thread YANG LI
The pointer p is being used but it isn't being initialized, need to assign a NULL to it. Signed-off-by: YANG LI Reported-by: Abaci --- net/9p/trans_virtio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/9p/trans_virtio.c b/net/9p/trans_virtio.c index 93f2f86..d4d635f 1

[PATCH] liquidio: fix: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'.

2020-12-29 Thread YANG LI
For safety, modify '%u' to '%d' to keep the type consistent. Signed-off-by: YANG LI Reported-by: Abaci --- drivers/net/ethernet/cavium/liquidio/lio_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/cavium/liquidio/lio_core.c b/drivers/net/ether

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Jason Wang
On 2020/12/29 下午7:53, Eli Cohen wrote: + +static struct vhost_vdpa_as *vhost_vdpa_alloc_as(struct vhost_vdpa *v, u32 asid) +{ + struct hlist_head *head = &v->as[asid % VHOST_VDPA_IOTLB_BUCKETS]; + struct vhost_vdpa_as *as; + + if (asid_to_as(v, asid)) + return N

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Jason Wang
On 2020/12/29 下午8:05, Eli Cohen wrote: + +static int vhost_vdpa_remove_as(struct vhost_vdpa *v, u32 asid) The return value is never interpreted. I think it should either be made void or return values checked. Right, will make it void. +{ + struct vhost_vdpa_as *as = asid_to_as(v,

[PATCH] mlx4: style: replace zero-length array with flexible-array member.

2020-12-29 Thread YANG LI
There is a regular need in the kernel to provide a way to declare having a dynamically sized set of trailing elements in a structure. Kernel code should always use "flexible array members"[1] for these cases. The older style of one-element or zero-length arrays should no longer be used[2]. [1] htt

Re: [PATCH] liquidio: style: Identical condition and return expression 'retval', return value is always 0.

2020-12-29 Thread Joe Perches
On Wed, 2020-12-30 at 14:07 +0800, YANG LI wrote: > The warning was because of the following line in function > liquidio_set_fec(): > > retval = wait_for_sc_completion_timeout(oct, sc, 0); > if (retval) > return (-EIO); I presume abaci is a robot Perhaps also the robot could look for c

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Jason Wang
On 2020/12/29 下午7:41, Eli Cohen wrote: On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: This patch converts the vhost-vDPA device to support multiple IOTLBs tagged via ASID via hlist. This will be used for supporting multiple address spaces in the following patches. Signed-off-by:

Re: [RFC v2 09/13] vduse: Add support for processing vhost iotlb message

2020-12-29 Thread Jason Wang
On 2020/12/29 下午6:26, Yongji Xie wrote: On Tue, Dec 29, 2020 at 5:11 PM Jason Wang wrote: - Original Message - On Mon, Dec 28, 2020 at 4:43 PM Jason Wang wrote: On 2020/12/28 下午4:14, Yongji Xie wrote: I see. So all the above two questions are because VHOST_IOTLB_INVALIDATE is e

[PATCH] liquidio: style: Identical condition and return expression 'retval', return value is always 0.

2020-12-29 Thread YANG LI
The warning was because of the following line in function liquidio_get_fec(): retval = wait_for_sc_completion_timeout(oct, sc, 0); if (retval) return retval; If this statement is not true, retval must be 0 and not updated later. So, It is better to return 0 directly. Signed-off-by: Y

[PATCH] liquidio: style: Identical condition and return expression 'retval', return value is always 0.

2020-12-29 Thread YANG LI
The warning was because of the following line in function liquidio_set_fec(): retval = wait_for_sc_completion_timeout(oct, sc, 0); if (retval) return (-EIO); If this statement is not true, retval must be 0 and not updated later. So, It is better to return 0 directly. Signed-off-by: Y

Re: [PATCH 10/21] vhost: support ASID in IOTLB API

2020-12-29 Thread Jason Wang
On 2020/12/29 下午6:20, Eli Cohen wrote: -static int vhost_process_iotlb_msg(struct vhost_dev *dev, +static int vhost_process_iotlb_msg(struct vhost_dev *dev, u16 asid, struct vhost_iotlb_msg *msg) { int ret = 0; + if (asid != 0) + re

Registering IRQ for MT7530 internal PHYs

2020-12-29 Thread DENG Qingfang
Hi, I added MT7530 IRQ support and registered its internal PHYs to IRQ. It works but my patch used two hacks. 1. Removed phy_drv_supports_irq check, because config_intr and handle_interrupt are not set for Generic PHY. 2. Allocated ds->slave_mii_bus before calling ds->ops->setup, because we cann

Re: [PATCH 07/21] vdpa: multiple address spaces support

2020-12-29 Thread Jason Wang
On 2020/12/29 下午3:28, Eli Cohen wrote: @@ -43,6 +43,8 @@ struct vdpa_vq_state { * @index: device index * @features_valid: were features initialized? for legacy guests * @nvqs: the number of virtqueues + * @ngroups: the number of virtqueue groups + * @nas: the number of address spaces

Re: [PATCH 07/21] vdpa: multiple address spaces support

2020-12-29 Thread Jason Wang
On 2020/12/29 下午3:28, Eli Cohen wrote: @@ -43,6 +43,8 @@ struct vdpa_vq_state { * @index: device index * @features_valid: were features initialized? for legacy guests * @nvqs: the number of virtqueues + * @ngroups: the number of virtqueue groups + * @nas: the number of address spaces

RE: [PATCH] rtw88: coex: remove useless if and else

2020-12-29 Thread Pkshih
> -Original Message- > From: Tian Tao [mailto:tiant...@hisilicon.com] > Sent: Tuesday, December 22, 2020 8:29 PM > To: tony0620e...@gmail.com; kv...@codeaurora.org; da...@davemloft.net; > k...@kernel.org > Cc: linux-wirel...@vger.kernel.org; netdev@vger.kernel.org > Subject: [PATCH] rtw8

Re: inconsistent lock state in ila_xlat_nl_cmd_add_mapping

2020-12-29 Thread Jakub Kicinski
On Tue, 29 Dec 2020 17:52:56 -0800 Cong Wang wrote: > On Tue, Dec 29, 2020 at 5:39 PM Jakub Kicinski wrote: > > > > On Mon, 13 Aug 2018 21:40:03 -0700 syzbot wrote: > > > Hello, > > > > > > syzbot found the following crash on: > > > > > > HEAD commit:78cbac647e61 Merge branch > > > 'ip-fast

Re: inconsistent lock state in ila_xlat_nl_cmd_add_mapping

2020-12-29 Thread Cong Wang
On Tue, Dec 29, 2020 at 5:39 PM Jakub Kicinski wrote: > > On Mon, 13 Aug 2018 21:40:03 -0700 syzbot wrote: > > Hello, > > > > syzbot found the following crash on: > > > > HEAD commit:78cbac647e61 Merge branch 'ip-faster-in-order-IP-fragments' > > git tree: net-next > > console output: ht

[PATCH v2 net-next] net: kcm: Replace fput with sockfd_put

2020-12-29 Thread Zheng Yongjun
The function sockfd_lookup uses fget on the value that is stored in the file field of the returned structure, so fput should ultimately be applied to this value. This can be done directly, but it seems better to use the specific macro sockfd_put, which does the same thing. The refactoring propose

Re: inconsistent lock state in ila_xlat_nl_cmd_add_mapping

2020-12-29 Thread Jakub Kicinski
On Mon, 13 Aug 2018 21:40:03 -0700 syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:78cbac647e61 Merge branch 'ip-faster-in-order-IP-fragments' > git tree: net-next > console output: https://syzkaller.appspot.com/x/log.txt?x=14df482840 > kernel config:

[PATCH net] smc: fix out of bound access in smc_nl_get_sys_info()

2020-12-29 Thread Jakub Kicinski
smc_clc_get_hostname() sets the host pointer to a buffer which is not NULL-terminated (see smc_clc_init()). Reported-by: syzbot+f4708c391121cfc58...@syzkaller.appspotmail.com Fixes: 099b990bd11a ("net/smc: Add support for obtaining system information") Signed-off-by: Jakub Kicinski --- net/smc/s

Re: [PATCH v3 0/5] dwmac-meson8b: picosecond precision RX delay support

2020-12-29 Thread Martin Blumenstingl
Hi Jakub, On Mon, Dec 28, 2020 at 9:37 PM Jakub Kicinski wrote: > > On Thu, 24 Dec 2020 00:29:00 +0100 Martin Blumenstingl wrote: > > Hello, > > > > with the help of Jianxin Pan (many thanks!) the meaning of the "new" > > PRG_ETH1[19:16] register bits on Amlogic Meson G12A, G12B and SM1 SoCs > >

Re: BTFIDS: FAILED unresolved symbol udp6_sock

2020-12-29 Thread Qais Yousef
Hi Jiri On 12/29/20 18:34, Jiri Olsa wrote: > On Tue, Dec 29, 2020 at 03:13:52PM +, Qais Yousef wrote: > > Hi > > > > When I enable CONFIG_DEBUG_INFO_BTF I get the following error in the BTFIDS > > stage > > > > FAILED unresolved symbol udp6_sock > > > > I cross compile for arm64. My .c

[PATCH] mt76: Fix queue ID variable types after mcu queue split

2020-12-29 Thread Nathan Chancellor
Clang warns in both mt7615 and mt7915: drivers/net/wireless/mediatek/mt76/mt7915/mcu.c:271:9: warning: implicit conversion from enumeration type 'enum mt76_mcuq_id' to different enumeration type 'enum mt76_txq_id' [-Wenum-conversion] txq = MT_MCUQ_FWDL; ~ ^~

Re: UBSAN: shift-out-of-bounds in choke_change

2020-12-29 Thread Randy Dunlap
Hi bot, On 12/29/20 10:58 AM, syzbot wrote: > Hello, > > syzbot found the following issue on: > > HEAD commit:71c5f031 Merge tag 'docs-5.11-2' of git://git.lwn.net/linux > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=1510369350 > kernel config: ht

Re: [PATCH] CDC-NCM: remove "connected" log message

2020-12-29 Thread Roland Dreier
> I looked at them again and found that there is a way to get > the same effect that will make maintenance easier in the long run. > Could I send them to you later this week for testing? Yes, please. I have a good test setup now so I can easily try out patches. Thanks, Roland

Re: INFO: task hung in tls_sw_cancel_work_tx

2020-12-29 Thread Jakub Kicinski
On Fri, 07 Feb 2020 15:08:09 -0800 syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:90568ecf Merge tag 'kvm-5.6-2' of git://git.kernel.org/pub.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=16513809e0 > kernel config

Re: memory leak in tls_init

2020-12-29 Thread Jakub Kicinski
On Thu, 26 Sep 2019 18:19:09 -0700 syzbot wrote: > 2019/09/26 13:11:21 executed programs: 23 > BUG: memory leak > unreferenced object 0x88810e482a00 (size 512): >comm "syz-executor.4", pid 6874, jiffies 4295090041 (age 14.090s) >hex dump (first 32 bytes): > 00 00 00 00 00 00 00 00

UBSAN: shift-out-of-bounds in choke_change

2020-12-29 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:71c5f031 Merge tag 'docs-5.11-2' of git://git.lwn.net/linux git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1510369350 kernel config: https://syzkaller.appspot.com/x/.config?x=3e7e34a83d606100 dash

Re: [PATCH v5 bpf-next 2/2] net: xdp: introduce xdp_prepare_buff utility routine

2020-12-29 Thread Lorenzo Bianconi
> > + hard_start = page_address(rx_buffer->page) + > > + rx_buffer->page_offset - offset; > > + xdp_prepare_buff(&xdp, hard_start, offset, size, > > true); > > #if (PAGE_SIZE > 4096) > > /* At larger P

[PATCH] rxrpc: fix handling of an unsupported token type in rxrpc_read()

2020-12-29 Thread trix
From: Tom Rix clang static analysis reports this problem net/rxrpc/key.c:657:11: warning: Assigned value is garbage or undefined toksize = toksizes[tok++]; ^ ~~~ rxrpc_read() contains two loops. The first loop calculates the token sizes and s

Re: [PATCH net-next v2 0/2] Add support for DSFP transceiver type

2020-12-29 Thread Andrew Lunn
> Hi Andrew, > > Following this conversation, I wrote some pseudocode checking if I'm on > right path here. > Please review: > > struct eeprom_page { >     u8 page_number; >     u8 bank_number; >     u16 offset; >     u16 data_length; >     u8 *data; > } I'm wondering about o

Re: [PATCH net-next] net/mlx5: Use kzalloc for allocating only one thing

2020-12-29 Thread Joe Perches
On Tue, 2020-12-29 at 21:53 +0800, Zheng Yongjun wrote: > Use kzalloc rather than kcalloc(1,...) [] > diff --git a/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c > b/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c [] > @@ -1782,7 +1782,7 @@ static int dr_action_create_mo

Race Condition Observed in ARP Processing.

2020-12-29 Thread Chinmay Agarwal
Hi All, We found a crash while performing some automated stress tests on a 5.4 kernel based device. We found out that it there is a freed neighbour address which was still part of the gc_list and was leading to crash. Upon adding some debugs and checking neigh_put/neigh_hold/neigh_destroy calls

Re: [PATCH] xfrm: Fix wraparound in xfrm_policy_addr_delta()

2020-12-29 Thread Florian Westphal
Visa Hankala wrote: > Use three-way comparison for address elements to avoid integer > wraparound in the result of xfrm_policy_addr_delta(). > > This ensures that the search trees are built and traversed correctly > when the difference between compared address elements is larger > than INT_MAX.

Re: [PATCH v5 bpf-next 2/2] net: xdp: introduce xdp_prepare_buff utility routine

2020-12-29 Thread Daniel Borkmann
On 12/22/20 10:09 PM, Lorenzo Bianconi wrote: Introduce xdp_prepare_buff utility routine to initialize per-descriptor xdp_buff fields (e.g. xdp_buff pointers). Rely on xdp_prepare_buff() in all XDP capable drivers. Signed-off-by: Lorenzo Bianconi Overall looks good to me, just one small nit i

Re: [PATCH net-next] net: core: Replace fput with sockfd_put

2020-12-29 Thread patchwork-bot+netdevbpf
Hello: This patch was applied to bpf/bpf-next.git (refs/heads/master): On Tue, 29 Dec 2020 21:48:34 +0800 you wrote: > The function sockfd_lookup uses fget on the value that is stored in > the file field of the returned structure, so fput should ultimately be > applied to this value. This can be

[PATCH] xfrm: Fix wraparound in xfrm_policy_addr_delta()

2020-12-29 Thread Visa Hankala
Use three-way comparison for address elements to avoid integer wraparound in the result of xfrm_policy_addr_delta(). This ensures that the search trees are built and traversed correctly when the difference between compared address elements is larger than INT_MAX. Fixes: 9cf545ebd591d ("xfrm: poli

Re: [PATCH rfc 2/3] virtio-net: support receive timestamp

2020-12-29 Thread Willem de Bruijn
On Tue, Dec 29, 2020 at 4:23 AM Jason Wang wrote: > > > > - Original Message - > > On Mon, Dec 28, 2020 at 7:55 PM Michael S. Tsirkin wrote: > > > > > > On Mon, Dec 28, 2020 at 02:30:31PM -0500, Willem de Bruijn wrote: > > > > On Mon, Dec 28, 2020 at 12:29 PM Michael S. Tsirkin > > > > w

[PATCH net-next] octeontx2-af: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/marvell/octeontx2/af/cgx.c | 2 +- 1 file changed, 1 insertio

[PATCH net-next] net/mlx5: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c | 2 +- 1 file change

[PATCH net-next] iavf: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/intel/iavf/iavf_virtchnl.c | 2 +- 1 file changed, 1 insertio

[PATCH net-next] bnxt_en: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH net-next] liquidio: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/cavium/liquidio/lio_core.c | 2 +- 1 file changed, 1 insertio

[PATCH net-next] net: dsa: sja1105: Use kzalloc for allocating only one thing

2020-12-29 Thread Zheng Yongjun
Use kzalloc rather than kcalloc(1,...) The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ @@ - kcalloc(1, + kzalloc( ...) // Signed-off-by: Zheng Yongjun --- drivers/net/dsa/sja1105/sja1105_main.c | 2 +- 1 file changed, 1 insertion(+), 1 d

[PATCH net-next] cavium/liquidio: Use DEFINE_SPINLOCK() for spinlock

2020-12-29 Thread Zheng Yongjun
spinlock can be initialized automatically with DEFINE_SPINLOCK() rather than explicitly calling spin_lock_init(). Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/cavium/liquidio/octeon_device.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/caviu

[PATCH net-next] net: ixp4xx_eth: Use DEFINE_SPINLOCK() for spinlock

2020-12-29 Thread Zheng Yongjun
spinlock can be initialized automatically with DEFINE_SPINLOCK() rather than explicitly calling spin_lock_init(). Signed-off-by: Zheng Yongjun --- drivers/net/ethernet/xscale/ixp4xx_eth.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/xscale/ixp4xx_eth

[PATCH net-next] net: usb: Use DEFINE_SPINLOCK() for spinlock

2020-12-29 Thread Zheng Yongjun
spinlock can be initialized automatically with DEFINE_SPINLOCK() rather than explicitly calling spin_lock_init(). Signed-off-by: Zheng Yongjun --- drivers/net/usb/hso.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c index 2bb28

[PATCH net-next] net: tipc: Replace expression with offsetof()

2020-12-29 Thread Zheng Yongjun
Use the existing offsetof() macro instead of duplicating code. Signed-off-by: Zheng Yongjun --- net/tipc/monitor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tipc/monitor.c b/net/tipc/monitor.c index 6dce2abf436e..48fac3b17e40 100644 --- a/net/tipc/monitor.c +++ b/ne

[PATCH net-next] net: wan: Use DEFINE_SPINLOCK() for spinlock

2020-12-29 Thread Zheng Yongjun
spinlock can be initialized automatically with DEFINE_SPINLOCK() rather than explicitly calling spin_lock_init(). Signed-off-by: Zheng Yongjun --- drivers/net/wan/ixp4xx_hss.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/wan/ixp4xx_hss.c b/drivers/net/wan/ix

[PATCH net-next] net: wan: Replace simple_strtol by simple_strtoul

2020-12-29 Thread Zheng Yongjun
The simple_strtol() function is deprecated, use simple_strtoul() instead. Signed-off-by: Zheng Yongjun --- drivers/net/wan/sbni.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wan/sbni.c b/drivers/net/wan/sbni.c index 2fde439543fb..3092a09d3eaa 100644 --- a/driv

[PATCH net-next] net: kcm: Replace fput with sockfd_put

2020-12-29 Thread Zheng Yongjun
The function sockfd_lookup uses fget on the value that is stored in the file field of the returned structure, so fput should ultimately be applied to this value. This can be done directly, but it seems better to use the specific macro sockfd_put, which does the same thing. The problem was fixed u

[PATCH net-next] net: core: Replace fput with sockfd_put

2020-12-29 Thread Zheng Yongjun
The function sockfd_lookup uses fget on the value that is stored in the file field of the returned structure, so fput should ultimately be applied to this value. This can be done directly, but it seems better to use the specific macro sockfd_put, which does the same thing. The problem was fixed u

Re: [PATCH] CDC-NCM: remove "connected" log message

2020-12-29 Thread Oliver Neukum
Am Montag, den 28.12.2020, 23:56 -0800 schrieb Roland Dreier: > > Applied to net and queued for LTS, thanks! > > Thanks - is Oliver's series of 3 patches that get rid of the other > half of the log spam also on the way upstream? Hi, I looked at them again and found that there is a way to get the

Re: [PATCH 12/21] vhost-vdpa: introduce uAPI to get the number of virtqueue groups

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:09PM +0800, Jason Wang wrote: > Follows the vDPA support for multiple address spaces, this patch > introduce uAPI for the userspace to know the number of virtqueue > groups supported by the vDPA device. Can you explain what exactly you mean be userspace? Is it just qe

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

[PATCH RFC net-next 1/6] net: netdevice: Add operation ndo_sk_get_slave

2020-12-29 Thread Tariq Toukan
ndo_sk_get_slave returns a slave given a socket. Additionally, we implement a helper netdev_sk_get_lowest_dev() to get the lowest slave netdevice. Signed-off-by: Tariq Toukan --- include/linux/netdevice.h | 4 net/core/dev.c| 32 2 files changed

[PATCH RFC net-next 3/6] net/tls: Except bond interface from some TLS checks

2020-12-29 Thread Tariq Toukan
In the tls_dev_event handler, ignore tls_dev_ops requirement for bond interfaces, they do not exist as the interaction is done directly with the slave. Also, make the validate function pass when it's called with the upper bond interface. Signed-off-by: Tariq Toukan --- net/tls/tls_device.c

[PATCH RFC net-next 0/6] RFC: TLS TX HW offload for Bond

2020-12-29 Thread Tariq Toukan
Hi, This is an RFC of the series that opens TLS TX HW offload for bond interfaces. It allows them to benefit from capable slave devices. To keep simple track of the HW and SW TLS contexts, we bind each socket to a specific slave for the socket's whole lifetime. This is logically valid (and simila

[PATCH RFC net-next 4/6] net/bonding: Take IP hash logic into a helper

2020-12-29 Thread Tariq Toukan
Hash logic on L3 will be used in a downstream patch for one more use case. Take it to a function for a better code reuse. Signed-off-by: Tariq Toukan --- drivers/net/bonding/bond_main.c | 16 +++- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/drivers/net/bonding/bond

[PATCH RFC net-next 5/6] net/bonding: Implement ndo_sk_get_slave

2020-12-29 Thread Tariq Toukan
Support L3/4 sockets only, with xmit_hash_policy==LAYER34 and modes xor/802.3ad. Signed-off-by: Tariq Toukan --- drivers/net/bonding/bond_main.c | 90 + 1 file changed, 90 insertions(+) diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.

[PATCH RFC net-next 2/6] net/tls: Device offload to use lowest netdevice in chain

2020-12-29 Thread Tariq Toukan
Do not call the tls_dev_ops of upper devices. Instead, ask them for the proper slave and communicate with it directly. Signed-off-by: Tariq Toukan --- net/tls/tls_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tls/tls_device.c b/net/tls/tls_device.c index f7fb7d

[PATCH RFC net-next 6/6] net/bonding: Support TLS TX device offload

2020-12-29 Thread Tariq Toukan
Implement TLS TX device offload for bonding interfaces. This allows kTLS sockets running on a bond to benefit from the device offload on capable slaves. To allow a simple and fast maintenance of the TLS context in SW and slaves devices, we bind the TLS socket to a specific slave. We ask the bond d

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

[PATCH 3/3] vsock: support for SOCK_SEQPACKET socket.

2020-12-29 Thread Arseny Krasnov
1) Add socket ops for SOCK_SEQPACKET type. 2) For receive, create another loop. It looks like stream receive loop, but it doesn't call notify callbacks, it doesn't care about 'SO_SNDLOWAT' and 'SO_RCVLOWAT' values, it waits until whole record is

[PATCH 2/3] vhost/vsock: support for SOCK_SEQPACKET socket.

2020-12-29 Thread Arseny Krasnov
This patch simply adds transport ops and removes ignore of non-stream type of packets. Signed-off-by: Arseny Krasnov --- drivers/vhost/vsock.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/vhost/vsock.c b/drivers/vhost/vsock.c index a483cec31d5c..4a36e

[PATCH 1/3] vsock/virtio: support for SOCK_SEQPACKET socket.

2020-12-29 Thread Arseny Krasnov
To preserve message boundaries, new packet operation was added: to mark start of record(with record length in header). To send record, packet with start marker is sent first, then all data is transmitted as 'RW' packets. On receiver's side, length of record is known from packet with

Re: Re: [RFC v2 09/13] vduse: Add support for processing vhost iotlb message

2020-12-29 Thread Yongji Xie
On Tue, Dec 29, 2020 at 5:11 PM Jason Wang wrote: > > > > - Original Message - > > On Mon, Dec 28, 2020 at 4:43 PM Jason Wang wrote: > > > > > > > > > On 2020/12/28 下午4:14, Yongji Xie wrote: > > > >> I see. So all the above two questions are because > > > >> VHOST_IOTLB_INVALIDATE > > >

Re: [PATCH net-next v2 0/2] Add support for DSFP transceiver type

2020-12-29 Thread Vladyslav Tarasiuk
On 27-Nov-20 17:56, Andrew Lunn wrote: OK, but if the caching system is checking one time netlink and one time ioctl, it means this cache should be in user space, or did you mean to have this cache in kernel ? This is all in userspace, in the ethtool code. What about the global offset that w

Re: [PATCH 10/21] vhost: support ASID in IOTLB API

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:07PM +0800, Jason Wang wrote: > This patches allows userspace to send ASID based IOTLB message to > vhost. This idea is to use the reserved u32 field in the existing V2 > IOTLB message. Vhost device should advertise this capability via > VHOST_BACKEND_F_IOTLB_ASID back

Re: [PATCH rfc 2/3] virtio-net: support receive timestamp

2020-12-29 Thread Jason Wang
- Original Message - > On Mon, Dec 28, 2020 at 7:55 PM Michael S. Tsirkin wrote: > > > > On Mon, Dec 28, 2020 at 02:30:31PM -0500, Willem de Bruijn wrote: > > > On Mon, Dec 28, 2020 at 12:29 PM Michael S. Tsirkin > > > wrote: > > > > > > > > On Mon, Dec 28, 2020 at 11:22:32AM -0500, Wi

Re: [RFC v2 09/13] vduse: Add support for processing vhost iotlb message

2020-12-29 Thread Jason Wang
- Original Message - > On Mon, Dec 28, 2020 at 4:43 PM Jason Wang wrote: > > > > > > On 2020/12/28 下午4:14, Yongji Xie wrote: > > >> I see. So all the above two questions are because VHOST_IOTLB_INVALIDATE > > >> is expected to be synchronous. This need to be solved by tweaking the > > >

[PATCH v2 1/2] docs: networking: packet_mmap: fix formatting for C macros

2020-12-29 Thread Baruch Siach
The citation of macro definitions should appear in a code block. Signed-off-by: Baruch Siach --- Documentation/networking/packet_mmap.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/networking/packet_mmap.rst b/Documentation/networking/packet_mmap.rst index

[PATCH v2 2/2] docs: networking: packet_mmap: fix old config reference

2020-12-29 Thread Baruch Siach
Before commit 889b8f964f2f ("packet: Kill CONFIG_PACKET_MMAP.") there used to be a CONFIG_PACKET_MMAP config symbol that depended on CONFIG_PACKET. The text still implies that PACKET_MMAP can be disabled. Remove that from the text, as well as reference to old kernel versions. Also, drop reference

[PATCH net-next v3] net: mhi: Add raw IP mode support

2020-12-29 Thread Loic Poulain
MHI net is protocol agnostic, the payload protocol depends on the modem configuration, which can be either RMNET (IP muxing and aggregation) or raw IP. This patch adds support for incomming IPv4/IPv6 packets, that was previously unconditionnaly reported as RMNET packets. Signed-off-by: Loic Poulai

Re: [PATCH 2/4] ARM: dts: renesas: Add fck to etheravb-rcar-gen2 clock-names list

2020-12-29 Thread Sergei Shtylyov
On 29.12.2020 0:31, Adam Ford wrote: The bindings have been updated to support two clocks, but the original clock now requires the name fck. Add a clock-names list in the device tree with fck in it. Hopefully this won't break RPM... Signed-off-by: Adam Ford [...] MBR, Sergei

[PATCH bpf-next] xsk: build skb by page

2020-12-29 Thread Xuan Zhuo
This patch is used to construct skb based on page to save memory copy overhead. Taking into account the problem of addr unaligned, and the possibility of frame size greater than page in the future. The test environment is Aliyun ECS server. Test cmd: ``` xdpsock -i eth0 -t -S -s ``` Test resul

Re: [PATCH 4/4] net: ethernet: ravb: Name the AVB functional clock fck

2020-12-29 Thread Sergei Shtylyov
On 29.12.2020 0:31, Adam Ford wrote: The bindings have been updated to support two clocks, but the original clock now requires the name fck to distinguish it from the other. Signed-off-by: Adam Ford Reviewed-by: Sergei Shtylyov MBR, Sergei

Re: [PATCH 1/4] dt-bindings: net: renesas,etheravb: Add additional clocks

2020-12-29 Thread Sergei Shtylyov
Hello! On 29.12.2020 0:31, Adam Ford wrote: The AVB driver assumes there is an external clock, but it could be driven by an external clock. Driver can be driven by external clock? :-) In order to enable a programmable clock, it needs to be added to the clocks list and enabled in the dri