netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Guodong Xu <guodong.xu@linaro.org>
To: linux-wireless@vger.kernel.org, kvalo@codeaurora.org,
	eliad@wizery.com, guym@ti.com, arik@wizery.com, nsekhar@ti.com,
	luca@coelho.fi, ramrani@ti.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, guodong.xu@linaro.org
Subject: [PATCH] wlcore: align reg_ch_conf_last[] to 64bit
Date: Fri, 18 Sep 2015 20:37:27 +0800	[thread overview]
Message-ID: <1442579847-8138-1-git-send-email-guodong.xu@linaro.org> (raw)

Align fields reg_ch_conf_last and reg_ch_conf_pending of
struct wl1271{} to 64bit.

Without this, on 64bit ARM, wlcore_set_pending_regdomain_ch() fails at
the point it calls set_bit(ch_bit_idx, (long*)wl->reg_ch_conf_pending);
Here is the error message while doing iw wlan0 scan or connect:

[   10.666857] wlcore: IRQ work
[   10.670046] wlcore: intr: 0x40 (fw_rx_counter = 1, drv_rx_counter = 0, tx_results_counter = 0)
[   10.678697] wlcore: WL1271_ACX_INTR_DATA
[   10.682810] Unhandled fault: alignment fault (0x96000021) at 0xffffffc037a817f4
[   10.690139] Internal error: : 96000021 [#1] PREEMPT SMP
[   10.695366] Modules linked in:
[   10.698437] CPU: 3 PID: 894 Comm: irq/60-wl18xx Tainted: G        W       4.2.0-rc6-linaro-hikey #2
[   10.707501] Hardware name: HiKey Development Board (DT)
[   10.712733] task: ffffffc03a9d1680 ti: ffffffc039e18000 task.ti: ffffffc039e18000
[   10.720239] PC is at set_bit+0x14/0x30
[   10.724002] LR is at wlcore_set_pending_regdomain_ch+0x40/0x4c

Signed-off-by: Guodong Xu <guodong.xu@linaro.org>
---
 drivers/net/wireless/ti/wlcore/wlcore.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/ti/wlcore/wlcore.h b/drivers/net/wireless/ti/wlcore/wlcore.h
index a1b6040..906be6a 100644
--- a/drivers/net/wireless/ti/wlcore/wlcore.h
+++ b/drivers/net/wireless/ti/wlcore/wlcore.h
@@ -318,7 +318,7 @@ struct wl1271 {
 	bool watchdog_recovery;
 
 	/* Reg domain last configuration */
-	u32 reg_ch_conf_last[2];
+	u32 reg_ch_conf_last[2]  __aligned(8);
 	/* Reg domain pending configuration */
 	u32 reg_ch_conf_pending[2];
 
-- 
1.9.1

                 reply	other threads:[~2015-09-18 12:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1442579847-8138-1-git-send-email-guodong.xu@linaro.org \
    --to=guodong.xu@linaro.org \
    --cc=arik@wizery.com \
    --cc=eliad@wizery.com \
    --cc=guym@ti.com \
    --cc=kvalo@codeaurora.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=luca@coelho.fi \
    --cc=netdev@vger.kernel.org \
    --cc=nsekhar@ti.com \
    --cc=ramrani@ti.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;
as well as URLs for NNTP newsgroup(s).