* [PATCH] igb: Allocate MSI-X vector when testing
@ 2022-11-22 12:13 ` Akihiko Odaki
0 siblings, 0 replies; 5+ messages in thread
From: Akihiko Odaki @ 2022-11-22 12:13 UTC (permalink / raw)
Cc: linux-kernel, netdev, intel-wired-lan, Jesse Brandeburg,
Tony Nguyen, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Yan Vugenfirer, Yuri Benditovich, Akihiko Odaki
Allocate MSI-X vector when testing interrupts, otherwise the tests will
not work.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
---
drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c
index e5f3e7680dc6..ff911af16a4b 100644
--- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
+++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
@@ -1413,6 +1413,8 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
*data = 1;
return -1;
}
+ wr32(E1000_IVAR_MISC, E1000_IVAR_VALID << 8);
+ wr32(E1000_EIMS, BIT(0));
} else if (adapter->flags & IGB_FLAG_HAS_MSI) {
shared_int = false;
if (request_irq(irq,
--
2.38.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Intel-wired-lan] [PATCH] igb: Allocate MSI-X vector when testing
@ 2022-11-22 12:13 ` Akihiko Odaki
0 siblings, 0 replies; 5+ messages in thread
From: Akihiko Odaki @ 2022-11-22 12:13 UTC (permalink / raw)
Cc: netdev, linux-kernel, Yuri Benditovich, Eric Dumazet,
Jakub Kicinski, Yan Vugenfirer, intel-wired-lan, Paolo Abeni,
David S. Miller
Allocate MSI-X vector when testing interrupts, otherwise the tests will
not work.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
---
drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c
index e5f3e7680dc6..ff911af16a4b 100644
--- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
+++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
@@ -1413,6 +1413,8 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
*data = 1;
return -1;
}
+ wr32(E1000_IVAR_MISC, E1000_IVAR_VALID << 8);
+ wr32(E1000_EIMS, BIT(0));
} else if (adapter->flags & IGB_FLAG_HAS_MSI) {
shared_int = false;
if (request_irq(irq,
--
2.38.1
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Intel-wired-lan] [PATCH] igb: Allocate MSI-X vector when testing
2022-11-22 12:13 ` [Intel-wired-lan] " Akihiko Odaki
(?)
@ 2022-11-22 12:15 ` Maciej Fijalkowski
2022-11-22 13:17 ` [Intel-wired-lan] " Akihiko Odaki
-1 siblings, 1 reply; 5+ messages in thread
From: Maciej Fijalkowski @ 2022-11-22 12:15 UTC (permalink / raw)
To: Akihiko Odaki
Cc: netdev, linux-kernel, Yuri Benditovich, Eric Dumazet,
Jakub Kicinski, Yan Vugenfirer, intel-wired-lan,
no To-header on input, Paolo Abeni, David S. Miller
On Tue, Nov 22, 2022 at 09:13:12PM +0900, Akihiko Odaki wrote:
> Allocate MSI-X vector when testing interrupts, otherwise the tests will
> not work.
Hi,
can you say a bit more about why current code was broken? And also what is
the current result of that ethtool test?
Also this is a fix, please provide Fixes: tag and route it to net tree.
>
> Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
> ---
> drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c
> index e5f3e7680dc6..ff911af16a4b 100644
> --- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
> +++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
> @@ -1413,6 +1413,8 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
> *data = 1;
> return -1;
> }
> + wr32(E1000_IVAR_MISC, E1000_IVAR_VALID << 8);
> + wr32(E1000_EIMS, BIT(0));
> } else if (adapter->flags & IGB_FLAG_HAS_MSI) {
> shared_int = false;
> if (request_irq(irq,
> --
> 2.38.1
>
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] igb: Allocate MSI-X vector when testing
2022-11-22 12:15 ` Maciej Fijalkowski
@ 2022-11-22 13:17 ` Akihiko Odaki
0 siblings, 0 replies; 5+ messages in thread
From: Akihiko Odaki @ 2022-11-22 13:17 UTC (permalink / raw)
To: Maciej Fijalkowski
Cc: linux-kernel, netdev, intel-wired-lan, Jesse Brandeburg,
Tony Nguyen, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Yan Vugenfirer, Yuri Benditovich
On 2022/11/22 21:15, Maciej Fijalkowski wrote:
> On Tue, Nov 22, 2022 at 09:13:12PM +0900, Akihiko Odaki wrote:
>> Allocate MSI-X vector when testing interrupts, otherwise the tests will
>> not work.
>
> Hi,
>
> can you say a bit more about why current code was broken? And also what is
> the current result of that ethtool test?
>
> Also this is a fix, please provide Fixes: tag and route it to net tree.
Hi, I have just sent v2, please check it out.
Regarding Fixes: tag, I couldn't tell when the bug appeared. The
modified function, igb_intr_test() lacked the interrupt allocation code
from the start. My guess is that some code in igb_reset() or after the
function had code to allocate interrupts in the past and later removed.
But I couldn't find such code.
Regards,
Akihiko Odaki
>
>>
>> Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
>> ---
>> drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> index e5f3e7680dc6..ff911af16a4b 100644
>> --- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> +++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> @@ -1413,6 +1413,8 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
>> *data = 1;
>> return -1;
>> }
>> + wr32(E1000_IVAR_MISC, E1000_IVAR_VALID << 8);
>> + wr32(E1000_EIMS, BIT(0));
>> } else if (adapter->flags & IGB_FLAG_HAS_MSI) {
>> shared_int = false;
>> if (request_irq(irq,
>> --
>> 2.38.1
>>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Intel-wired-lan] [PATCH] igb: Allocate MSI-X vector when testing
@ 2022-11-22 13:17 ` Akihiko Odaki
0 siblings, 0 replies; 5+ messages in thread
From: Akihiko Odaki @ 2022-11-22 13:17 UTC (permalink / raw)
To: Maciej Fijalkowski
Cc: netdev, linux-kernel, Yuri Benditovich, Eric Dumazet,
Jakub Kicinski, Yan Vugenfirer, intel-wired-lan, Paolo Abeni,
David S. Miller
On 2022/11/22 21:15, Maciej Fijalkowski wrote:
> On Tue, Nov 22, 2022 at 09:13:12PM +0900, Akihiko Odaki wrote:
>> Allocate MSI-X vector when testing interrupts, otherwise the tests will
>> not work.
>
> Hi,
>
> can you say a bit more about why current code was broken? And also what is
> the current result of that ethtool test?
>
> Also this is a fix, please provide Fixes: tag and route it to net tree.
Hi, I have just sent v2, please check it out.
Regarding Fixes: tag, I couldn't tell when the bug appeared. The
modified function, igb_intr_test() lacked the interrupt allocation code
from the start. My guess is that some code in igb_reset() or after the
function had code to allocate interrupts in the past and later removed.
But I couldn't find such code.
Regards,
Akihiko Odaki
>
>>
>> Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
>> ---
>> drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> index e5f3e7680dc6..ff911af16a4b 100644
>> --- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> +++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
>> @@ -1413,6 +1413,8 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
>> *data = 1;
>> return -1;
>> }
>> + wr32(E1000_IVAR_MISC, E1000_IVAR_VALID << 8);
>> + wr32(E1000_EIMS, BIT(0));
>> } else if (adapter->flags & IGB_FLAG_HAS_MSI) {
>> shared_int = false;
>> if (request_irq(irq,
>> --
>> 2.38.1
>>
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-11-22 13:17 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-22 12:13 [PATCH] igb: Allocate MSI-X vector when testing Akihiko Odaki
2022-11-22 12:13 ` [Intel-wired-lan] " Akihiko Odaki
2022-11-22 12:15 ` Maciej Fijalkowski
2022-11-22 13:17 ` Akihiko Odaki
2022-11-22 13:17 ` [Intel-wired-lan] " Akihiko Odaki
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.