From: "Pali Rohár" <pali.rohar@gmail.com>
To: Michal Kazior <michal.kazior@tieto.com>
Cc: Kalle Valo <kvalo@codeaurora.org>, Pavel Machek <pavel@ucw.cz>,
Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>,
Sebastian Reichel <sre@kernel.org>,
Aaro Koskinen <aaro.koskinen@iki.fi>,
Tony Lindgren <tony@atomide.com>,
linux-wireless <linux-wireless@vger.kernel.org>,
Network Development <netdev@vger.kernel.org>,
linux-kernel@vger.kernel.org
Subject: Re: wl1251 & mac address & calibration data
Date: Tue, 22 Nov 2016 16:31:41 +0100 [thread overview]
Message-ID: <20161122153141.GT13735@pali> (raw)
In-Reply-To: <CA+BoTQm5yZYccMherMnmxZ0_b2PqkCWf_0nBoRLzsro-Ujz1eQ@mail.gmail.com>
On Tuesday 22 November 2016 16:22:57 Michal Kazior wrote:
> On 21 November 2016 at 16:51, Pali Rohár <pali.rohar@gmail.com> wrote:
> > On Friday 11 November 2016 18:20:50 Pali Rohár wrote:
> >> Hi! I will open discussion about mac address and calibration data for
> >> wl1251 wireless chip again...
> >>
> >> Problem: Mac address & calibration data for wl1251 chip on Nokia N900
> >> are stored on second nand partition (mtd1) in special proprietary format
> >> which is used only for Nokia N900 (probably on N8x0 and N9 too).
> >> Wireless driver wl1251.ko cannot work without mac address and
> >> calibration data.
>
> Same problem applies to some ath9k/ath10k supported routers. Some even
> carry mac address as implicit offset from ethernet mac address. As far
> as I understand OpenWRT cooks cal blobs on first boot prior to loading
> modules.
So... wl1251 on Nokia N900 is not alone and this problem is there for
more drivers and devices. Which means we should come up with some
generic solution.
> >> Absence of mac address cause that driver generates random mac address at
> >> every kernel boot which has couple of problems (unstable identifier of
> >> wireless device due to udev permanent storage rules; unpredictable
> >> behaviour for dhcp mac address assignment, mac address filtering, ...).
> >>
> >> Currently there is no way to set (permanent) mac address for network
> >> interface from userspace. And it does not make sense to implement in
> >> linux kernel large parser for proprietary format of second nand
> >> partition where is mac address stored only for one device -- Nokia N900.
> >>
> >> Driver wl1251.ko loads calibration data via request_firmware() for file
> >> wl1251-nvs.bin. There are some "example" calibration file in linux-
> >> firmware repository, but it is not suitable for normal usage as real
> >> calibration data are per-device specific.
>
> You could hook up a script that cooks up the cal/mac file via
> modprobe's install hook, no?
Via modprobe hook I can either pass custom module parameter or call any
other system (shell) commands.
As wl1251.ko does not accept mac_address as module parameter, such
modprobe hook does not help -- as there is absolutely no way from
userspace to set or change (permanent) mac address.
--
Pali Rohár
pali.rohar@gmail.com
next prev parent reply other threads:[~2016-11-22 15:31 UTC|newest]
Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-11 17:20 wl1251 & mac address & calibration data Pali Rohár
2016-11-21 15:51 ` Pali Rohár
2016-11-22 15:22 ` Michal Kazior
2016-11-22 15:22 ` Michal Kazior
2016-11-22 15:31 ` Pali Rohár [this message]
2016-11-22 16:14 ` Michal Kazior
2016-11-22 16:14 ` Michal Kazior
2016-11-22 17:05 ` Pali Rohár
2016-11-23 8:24 ` Arend Van Spriel
2016-11-23 22:23 ` Pavel Machek
2016-11-23 22:39 ` Pali Rohár
2016-11-24 7:51 ` Pavel Machek
2016-11-24 8:33 ` Pali Rohár
2016-11-24 15:13 ` Sebastian Reichel
2016-11-24 15:20 ` Pali Rohár
2016-11-24 15:31 ` Ivaylo Dimitrov
2016-11-24 16:08 ` Sebastian Reichel
2016-11-24 16:49 ` Pali Rohár
2016-11-24 18:11 ` Sebastian Reichel
2016-11-24 18:35 ` Pali Rohár
2016-12-15 8:18 ` Kalle Valo
2016-12-15 8:18 ` Kalle Valo
2016-12-15 15:33 ` Pali Rohár
2016-12-15 20:12 ` Arend Van Spriel
2016-12-16 2:03 ` Luis R. Rodriguez
2016-12-16 7:25 ` Daniel Wagner
2016-12-16 7:25 ` Daniel Wagner
2016-12-16 10:40 ` Pali Rohár
2016-12-16 10:40 ` Pali Rohár
2016-12-18 10:49 ` Arend Van Spriel
2016-12-18 10:49 ` Arend Van Spriel
2016-12-18 11:04 ` Pali Rohár
2016-12-18 11:04 ` Pali Rohár
2016-12-18 11:54 ` Arend Van Spriel
2016-12-18 11:54 ` Arend Van Spriel
2016-12-18 12:09 ` Pali Rohár
2016-12-18 12:09 ` Pali Rohár
2016-12-18 20:08 ` Arend Van Spriel
2016-12-18 20:08 ` Arend Van Spriel
2016-12-20 11:47 ` Kalle Valo
2016-12-20 11:47 ` Kalle Valo
2016-12-20 11:47 ` Kalle Valo
2016-12-20 16:56 ` Tony Lindgren
2016-12-20 16:56 ` Tony Lindgren
2016-12-20 17:06 ` Pali Rohár
2016-12-20 17:06 ` Pali Rohár
2016-12-20 17:11 ` Kalle Valo
2016-12-20 17:11 ` Kalle Valo
2016-12-20 17:11 ` Kalle Valo
2016-12-20 17:21 ` Tony Lindgren
2016-12-20 17:21 ` Tony Lindgren
2017-01-12 8:50 ` Pavel Machek
2017-01-12 8:50 ` Pavel Machek
2016-12-16 10:35 ` Pali Rohár
2016-12-16 10:35 ` Pali Rohár
2016-12-16 10:26 ` Pali Rohár
2016-12-16 10:26 ` Pali Rohár
2016-11-24 18:46 ` Aaro Koskinen
2016-11-26 17:17 ` Pavel Machek
2016-11-26 17:17 ` Pavel Machek
2016-11-26 17:20 ` Pali Rohár
2016-11-26 17:20 ` Pali Rohár
2016-12-05 23:51 ` Tony Lindgren
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=20161122153141.GT13735@pali \
--to=pali.rohar@gmail.com \
--cc=aaro.koskinen@iki.fi \
--cc=ivo.g.dimitrov.75@gmail.com \
--cc=kvalo@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=michal.kazior@tieto.com \
--cc=netdev@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=sre@kernel.org \
--cc=tony@atomide.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.