All of lore.kernel.org
 help / color / mirror / Atom feed
From: kamal heib <kamalheib1@gmail.com>
To: Zhu Yanjun <zyjzyj2000@gmail.com>
Cc: RDMA mailing list <linux-rdma@vger.kernel.org>,
	Doug Ledford <dledford@redhat.com>,
	Jason Gunthorpe <jgg@ziepe.ca>
Subject: Re: [PATCH for-rc] RDMA/rxe: Fix failure during driver load
Date: Tue, 1 Jun 2021 10:56:57 +0300	[thread overview]
Message-ID: <8649FCE4-EAEE-4DA9-AF51-FC6329F67C43@gmail.com> (raw)
In-Reply-To: <CAD=hENe9O+3Z9ck6G5+t9RaVpbqUL-edfa+b1-Ki5NZO0eJPPA@mail.gmail.com>



> On 1 Jun 2021, at 10:45, Zhu Yanjun <zyjzyj2000@gmail.com> wrote:
> 
> On Tue, Jun 1, 2021 at 1:58 PM Kamal Heib <kamalheib1@gmail.com> wrote:
>> 
>> To avoid the following failure when trying to load the rdma_rxe module
>> while IPv6 is disabled, Add a check to make sure that IPv6 is enabled
>> before trying to create the IPv6 UDP tunnel.
>> 
>> $ modprobe rdma_rxe
>> modprobe: ERROR: could not insert 'rdma_rxe': Operation not permitted
> 
> About this problem, this link:
> https://patchwork.kernel.org/project/linux-rdma/patch/20210413234252.12209-1-yanjun.zhu@intel.com/
> also tries to solve ipv6 problem.
> 
> Zhu Yanjun
> 

Yes, but this patch is fixing the problem more cleanly and I’ve tested it.

Could you please review and ACK this patch?

Thanks,
Kamal


>> 
>> Fixes: dfdd6158ca2c ("IB/rxe: Fix kernel panic in udp_setup_tunnel")
>> Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
>> ---
>> drivers/infiniband/sw/rxe/rxe_net.c | 14 ++++++++------
>> 1 file changed, 8 insertions(+), 6 deletions(-)
>> 
>> diff --git a/drivers/infiniband/sw/rxe/rxe_net.c b/drivers/infiniband/sw/rxe/rxe_net.c
>> index 01662727dca0..f353fc18769f 100644
>> --- a/drivers/infiniband/sw/rxe/rxe_net.c
>> +++ b/drivers/infiniband/sw/rxe/rxe_net.c
>> @@ -617,12 +617,14 @@ static int rxe_net_ipv6_init(void)
>> {
>> #if IS_ENABLED(CONFIG_IPV6)
>> 
>> -       recv_sockets.sk6 = rxe_setup_udp_tunnel(&init_net,
>> -                                               htons(ROCE_V2_UDP_DPORT), true);
>> -       if (IS_ERR(recv_sockets.sk6)) {
>> -               recv_sockets.sk6 = NULL;
>> -               pr_err("Failed to create IPv6 UDP tunnel\n");
>> -               return -1;
>> +       if (ipv6_mod_enabled()) {
>> +               recv_sockets.sk6 = rxe_setup_udp_tunnel(&init_net,
>> +                                       htons(ROCE_V2_UDP_DPORT), true);
>> +               if (IS_ERR(recv_sockets.sk6)) {
>> +                       recv_sockets.sk6 = NULL;
>> +                       pr_err("Failed to create IPv6 UDP tunnel\n");
>> +                       return -1;
>> +               }
>>        }
>> #endif
>>        return 0;
>> --
>> 2.26.3
>> 

  reply	other threads:[~2021-06-01  7:57 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-01  5:56 [PATCH for-rc] RDMA/rxe: Fix failure during driver load Kamal Heib
2021-06-01  7:45 ` Zhu Yanjun
2021-06-01  7:56   ` kamal heib [this message]
2021-06-01  8:11     ` Zhu Yanjun
2021-06-01  9:09       ` Kamal Heib
2021-06-01 15:59         ` Zhu Yanjun
2021-06-01 17:01           ` Jason Gunthorpe
2021-06-02  7:22             ` Zhu Yanjun
2021-06-02 13:10             ` Kamal Heib
2021-06-02 14:04               ` Yanjun Zhu
2021-06-02 23:31               ` Jason Gunthorpe

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=8649FCE4-EAEE-4DA9-AF51-FC6329F67C43@gmail.com \
    --to=kamalheib1@gmail.com \
    --cc=dledford@redhat.com \
    --cc=jgg@ziepe.ca \
    --cc=linux-rdma@vger.kernel.org \
    --cc=zyjzyj2000@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.