mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paolo Abeni <pabeni@redhat.com>
To: Philo Lu <lulie@linux.alibaba.com>, netdev@vger.kernel.org
Cc: willemdebruijn.kernel@gmail.com, davem@davemloft.net,
	edumazet@google.com, kuba@kernel.org, dsahern@kernel.org,
	antony.antony@secunet.com, steffen.klassert@secunet.com,
	linux-kernel@vger.kernel.org, dust.li@linux.alibaba.com,
	jakub@cloudflare.com, fred.cc@alibaba-inc.com,
	yubing.qiuyubing@alibaba-inc.com
Subject: Re: [PATCH v5 net-next 1/3] net/udp: Add a new struct for hash2 slot
Date: Thu, 24 Oct 2024 16:38:16 +0200	[thread overview]
Message-ID: <ecacf1f2-48e0-4132-bbce-1be9fffc2798@redhat.com> (raw)
In-Reply-To: <0f2b58a6-7454-4579-9d20-be62de62573e@redhat.com>



On 10/24/24 16:31, Paolo Abeni wrote:
> On 10/18/24 13:45, Philo Lu wrote:
>> @@ -3438,16 +3436,17 @@ void __init udp_table_init(struct udp_table *table, const char *name)
>>  					      UDP_HTABLE_SIZE_MIN,
>>  					      UDP_HTABLE_SIZE_MAX);
>>  
>> -	table->hash2 = table->hash + (table->mask + 1);
>> +	table->hash2 = (void *)(table->hash + (table->mask + 1));
>>  	for (i = 0; i <= table->mask; i++) {
>>  		INIT_HLIST_HEAD(&table->hash[i].head);
>>  		table->hash[i].count = 0;
>>  		spin_lock_init(&table->hash[i].lock);
>>  	}
>>  	for (i = 0; i <= table->mask; i++) {
>> -		INIT_HLIST_HEAD(&table->hash2[i].head);
>> -		table->hash2[i].count = 0;
>> -		spin_lock_init(&table->hash2[i].lock);
>> +		INIT_HLIST_HEAD(&table->hash2[i].hslot.head);
>> +		table->hash2[i].hslot.count = 0;
>> +		spin_lock_init(&table->hash2[i].hslot.lock);
>> +		table->hash2[i].hash4_cnt = 0;
> 
> Does not build for CONFIG_BASE_SMALL=y kernels. You need to put all the
> hash4_cnt access under compiler guards.

I see now it's fixed in the next patch, but it's not good enough: we
want to preserve bisectability. You should introduce
udp_table_hash4_init() in this patch.

Thanks,

Paolo


  reply	other threads:[~2024-10-24 14:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-18 11:45 [PATCH v5 net-next 0/3] udp: Add 4-tuple hash for connected sockets Philo Lu
2024-10-18 11:45 ` [PATCH v5 net-next 1/3] net/udp: Add a new struct for hash2 slot Philo Lu
2024-10-24 14:31   ` Paolo Abeni
2024-10-24 14:38     ` Paolo Abeni [this message]
2024-10-18 11:45 ` [PATCH v5 net-next 2/3] net/udp: Add 4-tuple hash list basis Philo Lu
2024-10-18 11:45 ` [PATCH v5 net-next 3/3] ipv4/udp: Add 4-tuple hash for connected socket Philo Lu
2024-10-24 15:01   ` Paolo Abeni
2024-10-24 15:04     ` Paolo Abeni
2024-10-25  3:50     ` Philo Lu
2024-10-25  9:02       ` Paolo Abeni
2024-10-26  1:39         ` Philo Lu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ecacf1f2-48e0-4132-bbce-1be9fffc2798@redhat.com \
    --to=pabeni@redhat.com \
    --cc=antony.antony@secunet.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=dust.li@linux.alibaba.com \
    --cc=edumazet@google.com \
    --cc=fred.cc@alibaba-inc.com \
    --cc=jakub@cloudflare.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lulie@linux.alibaba.com \
    --cc=netdev@vger.kernel.org \
    --cc=steffen.klassert@secunet.com \
    --cc=willemdebruijn.kernel@gmail.com \
    --cc=yubing.qiuyubing@alibaba-inc.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®