[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250115082721.732ba8d2@canb.auug.org.au>
Date: Wed, 15 Jan 2025 08:27:21 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Jason Gunthorpe <jgg@...dia.com>
Cc: Doug Ledford <dledford@...hat.com>, Bernard Metzler
<bmt@...ich.ibm.com>, Junxian Huang <huangjunxian6@...ilicon.com>, Leon
Romanovsky <leon@...nel.org>, Linux Kernel Mailing List
<linux-kernel@...r.kernel.org>, Linux Next Mailing List
<linux-next@...r.kernel.org>, Yuyu Li <liyuyu6@...wei.com>
Subject: Re: linux-next: manual merge of the rdma tree with Linus' tree
Hi Jason,
On Tue, 14 Jan 2025 16:48:28 -0400 Jason Gunthorpe <jgg@...dia.com> wrote:
>
> I think we need to retain the ib_get_curr_port_state() call:
Why? It is no longer used to determine the attr->phys-state value and
then attr->state is set again just below. And
ib_get_curr_port_state(ndev) dose not appear to have side effects.
> --- drivers/infiniband/sw/siw/siw_verbs.c 2025-01-14 16:37:02.023738738 -0400
> +++ /home/jgg/oss/testing-k.o/drivers/infiniband/sw/siw/siw_verbs.c 2025-01-14 16:42:50.797896811 -0400
> @@ -189,6 +189,7 @@
> attr->max_msg_sz = -1;
> attr->max_mtu = ib_mtu_int_to_enum(ndev->max_mtu);
> attr->active_mtu = ib_mtu_int_to_enum(READ_ONCE(ndev->mtu));
> + attr->state = ib_get_curr_port_state(ndev);
> attr->phys_state = (netif_running(ndev) && netif_carrier_ok(ndev)) ?
> IB_PORT_PHYS_STATE_LINK_UP : IB_PORT_PHYS_STATE_DISABLED;
> attr->state = attr->phys_state == IB_PORT_PHYS_STATE_LINK_UP ?
--
Cheers,
Stephen Rothwell
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists