Re: [PATCH 1/8] mm: slab: provide krealloc_array()

2020-10-28 Thread Mike Rapoport
On Tue, Oct 27, 2020 at 01:17:18PM +0100, Bartosz Golaszewski wrote: > From: Bartosz Golaszewski > > When allocating an array of elements, users should check for > multiplication overflow or preferably use one of the provided helpers > like: kmalloc_array(). > > There's no krealloc_array() count

[PATCH v2] docs: proc.rst: meminfo: briefly describe gaps in memory accounting

2021-04-20 Thread Mike Rapoport
From: Mike Rapoport Add a paragraph that explains that it may happen that the counters in /proc/meminfo do not add up to the overall memory usage. Signed-off-by: Mike Rapoport --- v2: * Add brief changelog * Fix typo * Update example about network memory usage according to Eric's comme

Re: [PATCH v2] docs: proc.rst: meminfo: briefly describe gaps in memory accounting

2021-04-20 Thread Mike Rapoport
On Tue, Apr 20, 2021 at 03:13:54PM +0300, Mike Rapoport wrote: > From: Mike Rapoport > > Add a paragraph that explains that it may happen that the counters in > /proc/meminfo do not add up to the overall memory usage. > > Signed-off-by: Mike Rapoport Ooops, forgot to add M

Re: [PATCH v2] docs: proc.rst: meminfo: briefly describe gaps in memory accounting

2021-04-20 Thread Mike Rapoport
On Tue, Apr 20, 2021 at 02:24:30PM +0100, Matthew Wilcox wrote: > On Tue, Apr 20, 2021 at 03:13:54PM +0300, Mike Rapoport wrote: > > Add a paragraph that explains that it may happen that the counters in > > /proc/meminfo do not add up to the overall memory usage. > > ... th

Re: possible deadlock in cfg80211_netdev_notifier_call

2021-02-01 Thread Mike Rapoport
00 > > The issue was bisected to: > > commit cc9327f3b085ba5be5639a5ec3ce5b08a0f14a7c > Author: Mike Rapoport > Date: Thu Jan 28 07:42:40 2021 + > > mm: introduce memfd_secret system call to create "secret" memory areas > > bisection log:

Re: [PATCH] Add MHI bus support and driver for T99W175 5G modem

2021-03-16 Thread Mike Rapoport
On Tue, Mar 16, 2021 at 05:42:37AM -0700, Jarvis Jiang wrote: > T99W175 using MBIM or RmNet over PCIe interface with > MHI protocol support. > Ported from IPQ8072 platform, including MHI, MBIM, RmNet > > Supporting below PCI devices: > > PCI_DEVICE(0x17cb, 0x0300) > PCI_DEVICE(0x17cb, 0x0301)

[PATCH] trivial: netns: fix typo in 'struct net.passive' description

2019-08-21 Thread Mike Rapoport
Replace 'decided' with 'decide' so that comment would be /* To decide when the network namespace should be freed. */ Signed-off-by: Mike Rapoport --- include/net/net_namespace.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/net/net_names

[PATCH] docs-rst: networking: wire up msg_zerocopy

2018-01-07 Thread Mike Rapoport
Fix the following 'make htmldocs' complaint: Documentation/networking/msg_zerocopy.rst:: WARNING: document isn't included in any toctree. Signed-off-by: Mike Rapoport --- Documentation/networking/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH] mm: proc: add Sock to /proc/meminfo

2020-10-11 Thread Mike Rapoport
On Sat, Oct 10, 2020 at 06:38:54PM +0800, Muchun Song wrote: > The amount of memory allocated to sockets buffer can become significant. > However, we do not display the amount of memory consumed by sockets > buffer. In this case, knowing where the memory is consumed by the kernel > is very difficul

Re: [External] Re: [PATCH] mm: proc: add Sock to /proc/meminfo

2020-10-13 Thread Mike Rapoport
e here will be even > > > greater. > > > > > > > This is great, but you have not addressed my feedback. > > > > TCP memory allocations are bounded by /proc/sys/net/ipv4/tcp_mem > > > > Fact that the memory is forward allocated or not is a detail

Re: [External] Re: [PATCH] mm: proc: add Sock to /proc/meminfo

2020-10-13 Thread Mike Rapoport
On Tue, Oct 13, 2020 at 07:43:59AM -0700, Randy Dunlap wrote: > On 10/13/20 1:09 AM, Mike Rapoport wrote: > > On Mon, Oct 12, 2020 at 05:53:01PM +0800, Muchun Song wrote: > >> On Mon, Oct 12, 2020 at 5:24 PM Eric Dumazet > >> wrote: > >>> > >>>

Re: [External] Re: [PATCH] mm: proc: add Sock to /proc/meminfo

2020-10-13 Thread Mike Rapoport
On Tue, Oct 13, 2020 at 08:21:13AM -0700, Randy Dunlap wrote: > On 10/13/20 8:12 AM, Mike Rapoport wrote: > > On Tue, Oct 13, 2020 at 07:43:59AM -0700, Randy Dunlap wrote: > >> On 10/13/20 1:09 AM, Mike Rapoport wrote: > >>> On Mon, Oct 12, 2020 at 05:53:01PM +0800

Q: is it possible to use macvtap with lowerdev hotplug?

2019-01-09 Thread Mike Rapoport
Hi, I have a setup in which VMs are connected with macvtap to the network. The macvtap interfaces are attached to a physical NIC. There is a question if it is possible to hot-unplug - hot-plug the physical NIC and retain the VMs connectivity to the network (of course with some hiccup for the unpl

Q: is it possible to use macvtap with lowerdev hotplug?

2019-01-29 Thread Mike Rapoport
Hi, I have a setup in which VMs are connected with macvtap to the network. The macvtap interfaces are attached to a physical NIC. There is a question if it is possible to hot-unplug - hot-plug the physical NIC and retain the VMs connectivity to the network (of course with some hiccup for the unpl

[PATCH] docs/networking: fix formatting of Intel drivers documentation

2018-12-09 Thread Mike Rapoport
* Command Line Parameters * AutoNeg * Duplex ... Add overline heading adornment to document titles. Signed-off-by: Mike Rapoport --- Another interesting thing is that many of these documents have very similar or even identical titles. It would be nice to include the adapter name in the

[PATCH net-next] net/ipv6: stop leaking percpu memory in fib6 info

2018-10-08 Thread Mike Rapoport
The fib6_info_alloc() function allocates percpu memory to hold per CPU pointers to rt6_info, but this memory is never freed. Fix it. Fixes: a64efe142f5e ("net/ipv6: introduce fib6_info struct and helpers") Signed-off-by: Mike Rapoport Cc: sta...@vger.kernel.org --- net/ipv6/ip6_fib.c

[PATCH net] net/ipv6: stop leaking percpu memory in fib6 info

2018-10-08 Thread Mike Rapoport
The fib6_info_alloc() function allocates percpu memory to hold per CPU pointers to rt6_info, but this memory is never freed. Fix it. Fixes: a64efe142f5e ("net/ipv6: introduce fib6_info struct and helpers") Signed-off-by: Mike Rapoport Reviewed-by: David Ahern --- net/ipv6/ip6_fib.c

Re: [PATCH net-next] net/ipv6: stop leaking percpu memory in fib6 info

2018-10-08 Thread Mike Rapoport
On Mon, Oct 08, 2018 at 12:15:54PM -0600, David Ahern wrote: > On 10/8/18 6:06 AM, Mike Rapoport wrote: > > The fib6_info_alloc() function allocates percpu memory to hold per CPU > > pointers to rt6_info, but this memory is never freed. Fix it. > > > > Fixes: a64efe1

Re: [PATCH v3] selftests: add headers_install to lib.mk

2018-05-14 Thread Mike Rapoport
On Mon, May 14, 2018 at 01:58:09PM +0200, Anders Roxell wrote: > If the kernel headers aren't installed we can't build all the tests. > Add a new make target rule 'khdr' in the file lib.mk to generate the > kernel headers and that gets include for every test-dir Makefile that > includes lib.mk If t

Re: [PATCH 07/14] docs: add IRQ documentation at the core-api book

2020-05-02 Thread Mike Rapoport
Hello Mauro, On Fri, May 01, 2020 at 05:37:51PM +0200, Mauro Carvalho Chehab wrote: > There are 4 IRQ documentation files under Documentation/*.txt. > > Move them into a new directory (core-api/irq) and add a new > index file for it. Just curious, why IRQ docs got their subdirectory and DMA didn

Re: [PATCH 07/14] docs: add IRQ documentation at the core-api book

2020-05-02 Thread Mike Rapoport
On Sat, May 02, 2020 at 12:16:41PM +0200, Mauro Carvalho Chehab wrote: > Em Sat, 2 May 2020 10:41:33 +0300 > Mike Rapoport escreveu: > > > Hello Mauro, > > > > On Fri, May 01, 2020 at 05:37:51PM +0200, Mauro Carvalho Chehab wrote: > > > There are 4 IRQ doc

[PATCH 0/6] virtio_net: use common code for virtio_net_hdr and skb GSO conversion

2016-06-08 Thread Mike Rapoport
Hi, This patches introduce virtio_net_hdr_{from,to}_skb functions for conversion of GSO information between skb and virtio_net_hdr. Mike Rapoport (6): virtio_net: add _UAPI prefix to virtio_net header guards virtio_net: introduce virtio_net_hdr_{from,to}_skb macvtap: use common code for

[PATCH 2/6] virtio_net: introduce virtio_net_hdr_{from,to}_skb

2016-06-08 Thread Mike Rapoport
The code for conversion between virtio_net_hdr and skb GSO info is duplicated at several places. Let's put it to a common place to allow reuse. Signed-off-by: Mike Rapoport --- include/linux/virtio_net.h | 101 + 1 file changed, 101 inser

[PATCH 4/6] tuntap: use common code for virtio_net_hdr and skb GSO conversion

2016-06-08 Thread Mike Rapoport
Replace open coded conversion between virtio_net_hdr to skb GSO info with virtio_net_hdr_{from,to}_skb Signed-off-by: Mike Rapoport --- drivers/net/tun.c | 97 --- 1 file changed, 21 insertions(+), 76 deletions(-) diff --git a/drivers/net

[PATCH 6/6] packet: use common code for virtio_net_hdr and skb GSO conversion

2016-06-08 Thread Mike Rapoport
Replace open coded conversion between virtio_net_hdr to skb GSO info with virtio_net_hdr_from_skb Signed-off-by: Mike Rapoport --- net/packet/af_packet.c | 36 ++-- 1 file changed, 2 insertions(+), 34 deletions(-) diff --git a/net/packet/af_packet.c b/net/packet

[PATCH 1/6] virtio_net: add _UAPI prefix to virtio_net header guards

2016-06-08 Thread Mike Rapoport
This gives better namespacing and prevents conflicts with no-uapi version of virtio_net header that will be introduced in the following patch. Signed-off-by: Mike Rapoport --- include/uapi/linux/virtio_net.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/uapi

[PATCH 5/6] virtio_net: use common code for virtio_net_hdr and skb GSO conversion

2016-06-08 Thread Mike Rapoport
Replace open coded conversion between virtio_net_hdr to skb GSO info with virtio_net_hdr_{from,to}_skb Signed-off-by: Mike Rapoport --- drivers/net/virtio_net.c | 78 +++- 1 file changed, 10 insertions(+), 68 deletions(-) diff --git a/drivers/net

[PATCH 3/6] macvtap: use common code for virtio_net_hdr and skb GSO conversion

2016-06-08 Thread Mike Rapoport
Replace open coded conversion between virtio_net_hdr to skb GSO info with virtio_net_hdr_{from,to}_skb Signed-off-by: Mike Rapoport --- drivers/net/macvtap.c | 95 --- 1 file changed, 6 insertions(+), 89 deletions(-) diff --git a/drivers/net

Re: udp failures traced to e858fae2b0b8

2016-06-12 Thread Mike Rapoport
kernel-2.git$ git bisect good > e858fae2b0b8f41f0bed2cdffde25e7c97da38a7 is the first bad commit > commit e858fae2b0b8f41f0bed2cdffde25e7c97da38a7 > Author: Mike Rapoport > > virtio_net: use common code for virtio_net_hdr and skb GSO conversion > > On console I get the foll

Re: udp failures traced to e858fae2b0b8

2016-06-13 Thread Mike Rapoport
On Mon, Jun 13, 2016 at 07:48:39AM -0600, David Ahern wrote: > On 6/13/16 12:42 AM, Mike Rapoport wrote: > >Hi David, > > > >On Sun, Jun 12, 2016 at 08:47:20PM -0600, David Ahern wrote: > >>Mike: > >> > >>UDP tests in my vrf unit test suite are faili

[PATCH net-next] virtio_net: fix csum generation for virtio-net devices

2016-06-13 Thread Mike Rapoport
he current gso start/offset values. Fix it by moving the helper invocation before the mac pulling. Fixes: e858fae2b0b8 ("virtio_net: use common code for virtio_net_hdr and skb GSO conversion") Reported-by: David Ahern Signed-off-by: Mike Rapoport --- drivers/net/virtio_net.c | 8 ---

Re: [PATCH net-next] tun: fix csum generation for tap devices

2016-06-13 Thread Mike Rapoport
; skb_partial_csum_set() invocation after eth_type_trans(), which > invalidate the current gso start/offset values. > Fix it by moving the helper invocation before the mac pulling. > > Fixes: 34166093639 ("tuntap: use common code for virtio_net_hdr and skb GSO > conversion"

Re: [PATCH 2/2] tun: Rename a jump label in update_filter()

2016-08-21 Thread Mike Rapoport
On Mon, Aug 22, 2016 at 04:41:11AM +0300, Michael S. Tsirkin wrote: > On Sat, Aug 20, 2016 at 09:37:16AM +0200, SF Markus Elfring wrote: > > From: Markus Elfring > > Date: Sat, 20 Aug 2016 09:00:34 +0200 > > > > Adjust a jump target according to the Linux coding style convention. > > > > Signed-

Re: Designing a safe RX-zero-copy Memory Model for Networking

2016-12-12 Thread Mike Rapoport
Hello Jesper, On Mon, Dec 05, 2016 at 03:31:32PM +0100, Jesper Dangaard Brouer wrote: > Hi all, > > This is my design for how to safely handle RX zero-copy in the network > stack, by using page_pool[1] and modifying NIC drivers. Safely means > not leaking kernel info in pages mapped to userspace

Re: Designing a safe RX-zero-copy Memory Model for Networking

2016-12-12 Thread Mike Rapoport
On Mon, Dec 12, 2016 at 10:40:42AM +0100, Jesper Dangaard Brouer wrote: > > On Mon, 12 Dec 2016 10:38:13 +0200 Mike Rapoport > wrote: > > > Hello Jesper, > > > > On Mon, Dec 05, 2016 at 03:31:32PM +0100, Jesper Dangaard Brouer wrote: > > > Hi all, &g

Re: Designing a safe RX-zero-copy Memory Model for Networking

2016-12-13 Thread Mike Rapoport
On Mon, Dec 12, 2016 at 04:10:26PM +0100, Jesper Dangaard Brouer wrote: > On Mon, 12 Dec 2016 16:14:33 +0200 > Mike Rapoport wrote: > > > > They are copied :-) > > Presuming we are dealing only with vhost backend, the received skb > > eventually gets converted to

Re: Designing a safe RX-zero-copy Memory Model for Networking

2016-12-13 Thread Mike Rapoport
On Mon, Dec 12, 2016 at 06:49:03AM -0800, John Fastabend wrote: > On 16-12-12 06:14 AM, Mike Rapoport wrote: > >> > > We were not considered using XDP yet, so we've decided to limit the initial > > implementation to macvtap because we can ensure correspondence betwee