From: Ben Hutchings <ben@decadent.org.uk>
To: Francois Romieu <romieu@fr.zoreil.com>
Cc: "David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, Edward Hsu <edward_hsu@realtek.com.tw>
Subject: Re: [PATCH] r8169: partial support and phy init for the 8168d
Date: Sun, 01 Nov 2009 16:24:43 +0000 [thread overview]
Message-ID: <1257092683.3136.325.camel@localhost> (raw)
In-Reply-To: <20091007224420.GA20170@electric-eye.fr.zoreil.com>
[-- Attachment #1: Type: text/plain, Size: 1226 bytes --]
On Thu, 2009-10-08 at 00:44 +0200, Francois Romieu wrote:
> Extracted from Realtek's 8.012.00 r8168 driver.
There is a problem with this change:
[...]
> static void rtl8168d_1_hw_phy_config(void __iomem *ioaddr)
> {
[...]
> + static struct phy_reg phy_reg_init_2[] = {
> + { 0x1f, 0x0005 },
> + { 0x05, 0xffc2 },
> + { 0x1f, 0x0005 },
I interpret the following sequence of register writes as:
> + { 0x05, 0x8000 },
> + { 0x06, 0xf8f9 },
> + { 0x06, 0xfaef },
> + { 0x06, 0x59ee },
[...]
Write memory sequentially from 0x8000,
> + { 0x05, 0x83d4 },
> + { 0x06, 0x8000 },
> + { 0x05, 0x83d8 },
> + { 0x06, 0x8051 },
[...]
Change two vectors to point into what was just written.
I believe this is patching machine code in the PHY. And we do not have
source for that code, so it cannot possibly be distributed under GPL.
Please replace this with use of request_firmware() and submit the blob
to linux-firmware.git instead.
The same goes for phy_reg_init_1 in rtl8168d_2_hw_phy_config().
Ben.
--
Ben Hutchings
The generation of random numbers is too important to be left to chance.
- Robert Coveyou
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
next prev parent reply other threads:[~2009-11-01 16:24 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-07 22:44 [PATCH] r8169: partial support and phy init for the 8168d Francois Romieu
2009-10-13 17:49 ` Francois Romieu
2009-10-13 18:56 ` David Miller
2009-10-13 19:01 ` David Miller
2009-11-01 16:24 ` Ben Hutchings [this message]
2009-11-02 6:46 ` David Miller
2009-11-02 19:06 ` Ben Hutchings
2009-11-03 8:01 ` François romieu
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=1257092683.3136.325.camel@localhost \
--to=ben@decadent.org.uk \
--cc=davem@davemloft.net \
--cc=edward_hsu@realtek.com.tw \
--cc=netdev@vger.kernel.org \
--cc=romieu@fr.zoreil.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).