[OpenWrt-Devel] [PATCH] ramips:Fix mt7612 support for Xiaomi Mini.

Roger Pueyo Centelles rogerpueyo at rogerpueyo.com
Fri Feb 6 08:22:31 EST 2015


It works! I'm sending the patch right now! :)

2015-02-06 14:06 GMT+01:00 郭传鈜 <gch981213 at gmail.com>:

> Sorry I forget another thing.....
> It should be :
>   pcie-bridge {
>         mt76 at 0,0 {
>
> instead of:
>      pcie0 {
>         mt76 at 0,0 {
>
> I'll send another patch later....................
>
> 2015-02-06 20:22 GMT+08:00 Roger Pueyo Centelles <
> rogerpueyo at rogerpueyo.com>:
>
>> Hi,
>>
>> I added some prints to the eeprom.c file and saw that in function:
>>
>> static int mt76_get_of_eeprom(struct mt76_dev *dev, int len)
>> {
>>     int ret = -ENOENT;
>> #ifdef CONFIG_OF
>>     struct device_node *np = dev->dev->of_node;
>>     struct mtd_info *mtd;
>>     const __be32 *list;
>>     const char *part;
>>     phandle phandle;
>>     int offset = 0;
>>     int size;
>>     size_t retlen;
>>
>>     dev_printk(KERN_INFO, dev->dev, "mt76_get_of_eeprom. Step 0 (before
>> !np)");
>>
>>     if (!np)
>>         return -ENOENT;
>>
>>     dev_printk(KERN_INFO, dev->dev, "mt76_get_of_eeprom. Step 0 (after
>> !np)");
>> [...]
>>
>> if does not go further than (   if (!np)   ).
>>
>> Any ideas?
>>
>>
>>
>> 2015-02-04 23:13 GMT+01:00 John Crispin <blogic at openwrt.org>:
>>
>>>
>>>
>>> On 04/02/2015 22:11, Roger Pueyo Centelles wrote:
>>> > root at OpenWrt:/# hexdump -C /dev/mtd2
>>> > 00000000  20 76 05 01 64 09 80 01  66 5d ff ff ff ff ff ff  |
>>> > v..d...f]......|
>>> > 00000010  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > 00000020  ff ff ff ff ff ff ff ff  64 09 80 01 66 5c 00 d0
>>> > |........d...f\..|
>>> > 00000030  59 60 00 04 22 0c 04 04  ff ff 15 01 55 77 a8 aa
>>> > |Y`..".......Uw..|
>>> > 00000040  8c 88 ff ff 0d 00 00 00  00 00 00 00 00 00 ff ff
>>> > |................|
>>> > 00000050  ff ff 10 10 10 10 10 10  11 11 11 11 11 11 12 12
>>> > |................|
>>> > 00000060  12 12 12 12 12 12 13 13  13 14 14 14 15 15 80 ff
>>> > |................|
>>> > 00000070  ff ff 80 ff ff ff 00 f4  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > 00000080  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > *
>>> > 000000d0  1e 00 ff ff ff ff ff ff  ff ff ff ff ff ff 08 08
>>> > |................|
>>> > 000000e0  06 06 04 00 06 06 04 00  06 06 04 00 06 06 04 00
>>> > |................|
>>> > 000000f0  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > *
>>> > 00008000  62 76 00 00 64 09 80 01  66 5e 62 76 c3 14 00 00
>>>
>>>                          ^^ that is the mac at 0x8004
>>>
>>>
>>>
>>>
>>>
>>> > |bv..d...f^bv....|
>>> > 00008010  00 00 62 76 c3 14 00 00  00 00 ff ff ff ff ff ff
>>> > |..bv............|
>>> > 00008020  ff ff 37 d8 9d 00 60 7f  fd 9b ff ff ff ff ff ff
>>> > |..7...`.........|
>>> > 00008030  ff ff ff ff 22 ff 00 20  ff ff 9b 01 00 00 00 00  |...."..
>>> > ........|
>>> > 00008040  00 00 ff df 00 82 00 00  00 81 00 00 00 00 e0 01
>>> > |................|
>>> > 00008050  00 00 00 00 00 00 84 0a  1a 00 00 00 83 0b 1a 00
>>> > |................|
>>> > 00008060  00 00 7a 06 22 82 82 7a  06 22 82 82 78 08 22 82
>>> > |..z."..z."..x.".|
>>> > 00008070  82 7e 02 22 82 82 76 16  22 82 82 75 1c 22 82 82
>>> > |.~."..v."..u."..|
>>> > 00008080  79 0a 22 82 82 79 0a 22  82 82 7b 06 22 82 82 77
>>> > |y."..y."..{."..w|
>>> > 00008090  14 22 82 82 7e 05 22 82  82 79 11 22 82 82 00 1b
>>> > |."..~."..y."....|
>>> > 000080a0  c3 c3 c3 c3 00 00 c4 c4  c2 82 c4 c4 c2 82 00 00
>>> > |................|
>>> > 000080b0  00 00 c4 c4 c2 00 00 00  00 00 c2 c2 82 82 86 00
>>> > |................|
>>> > 000080c0  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > *
>>> > 000080f0  ff ff ff ff ff ff ff ff  22 ff ff ff ff ff ff ff
>>> > |........".......|
>>> > 00008100  0f ca 74 c5 e8 07 30 3d  01 b0 08 26 00 0e 04 15
>>> > |..t...0=...&....|
>>> > 00008110  00 8a 00 40 00 00 00 08  00 9d 08 00 12 c0 00 00
>>> > |... at ............|
>>> > 00008120  08 20 04 2a 90 00 00 24  01 04 54 08 d0 a0 28 20  |.
>>> > .*...$..T...( |
>>> > 00008130  ff ff ff ff ff ff ff 08  ff ff ff ff ff ff 00 00
>>> > |................|
>>> > 00008140  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > *
>>> > 000081e0  c0 81 82 c3 04 45 46 07  08 09 ff ff ff ff ff ff
>>> > |.....EF.........|
>>> > 000081f0  ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
>>> > |................|
>>> > *
>>> > 00010000
>>> >
>>> > The MACs are there, at 0x4, 0x28 and 0x8004.
>>> >
>>> > 2015-02-04 20:29 GMT+01:00 John Crispin <blogic at openwrt.org
>>> > <mailto:blogic at openwrt.org>>:
>>> >
>>> >
>>> >
>>> >     On 04/02/2015 20:18, Roger Pueyo Centelles wrote:
>>> >     > Hi,
>>> >     >
>>> >     > I tried with 0x8004 and I also got a random IP address. Actually,
>>> >     > I changed this block in in eeprom.c (line 571) [1]:
>>> >
>>> >     can you do a "hexdump -C /dev/mtd2" and paste the output please ?
>>> >
>>> >
>>>
>>
>>
>
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel at lists.openwrt.org
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/openwrt-devel/attachments/20150206/95ba00ea/attachment.htm>
-------------- next part --------------
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list