netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Schmidt <mschmidt@redhat.com>
To: netdev@vger.kernel.org
Cc: Yuval Mintz <Yuval.Mintz@qlogic.com>,
	Ariel Elior <Ariel.Elior@qlogic.com>
Subject: [PATCH net 2/7] bnx2x: fix sending VF->PF messages on big-endian
Date: Wed,  2 Mar 2016 13:47:06 +0100	[thread overview]
Message-ID: <1456922831-15071-3-git-send-email-mschmidt@redhat.com> (raw)
In-Reply-To: <1456922831-15071-1-git-send-email-mschmidt@redhat.com>

When a VF is sending a message to the PF, it needs to trigger the PF
to tell it the message is ready.
The trigger did not work on ppc64. No interrupt appeared in the PF.

The bug is due to confusion about the layout of struct trigger_vf_zone.
In bnx2x_send_msg2pf() the trigger is written using writeb(), not
writel(), so the attempt to define the struct with a reversed layout on
big-endian is counter-productive.

Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
---
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_hsi.h | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_hsi.h b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_hsi.h
index 90a4dba..47b13ed 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_hsi.h
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_hsi.h
@@ -5114,15 +5114,9 @@ struct vf_pf_channel_zone_trigger {
  * zone that triggers the in-bound interrupt
  */
 struct trigger_vf_zone {
-#if defined(__BIG_ENDIAN)
-	u16 reserved1;
-	u8 reserved0;
-	struct vf_pf_channel_zone_trigger vf_pf_channel;
-#elif defined(__LITTLE_ENDIAN)
 	struct vf_pf_channel_zone_trigger vf_pf_channel;
 	u8 reserved0;
 	u16 reserved1;
-#endif
 	u32 reserved2;
 };
 
-- 
2.5.0

  parent reply	other threads:[~2016-03-02 12:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-02 12:47 [PATCH net 0/7] bnx2x: endianness fixes Michal Schmidt
2016-03-02 12:47 ` [PATCH net 1/7] bnx2x: fix crash on big-endian when adding VLAN Michal Schmidt
2016-03-02 12:47 ` Michal Schmidt [this message]
2016-03-02 12:47 ` [PATCH net 3/7] bnx2x: fix receive of VF->PF mailbox messages by the PF on big-endian Michal Schmidt
2016-03-02 12:47 ` [PATCH net 4/7] bnx2x: access cfc_del_event only if the opcode is CFC_DEL Michal Schmidt
2016-03-02 12:47 ` [PATCH net 5/7] bnx2x: define fields of struct cfc_del_event_data as little-endian Michal Schmidt
2016-03-02 12:47 ` [PATCH net 6/7] bnx2x: define event data reserved fields " Michal Schmidt
2016-03-02 12:47 ` [PATCH net 7/7] bnx2x: fix indentation in bnx2x_sp_task() Michal Schmidt
2016-03-02 13:45 ` [PATCH net 0/7] bnx2x: endianness fixes Ariel Elior
2016-03-02 18:34 ` David Miller

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=1456922831-15071-3-git-send-email-mschmidt@redhat.com \
    --to=mschmidt@redhat.com \
    --cc=Ariel.Elior@qlogic.com \
    --cc=Yuval.Mintz@qlogic.com \
    --cc=netdev@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).