Send users mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://rt2x00.serialmonkey.com/mailman/listinfo/users_rt2x00.serialmonkey.com
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of users digest..."
Today's Topics:
1. Re: How can I backport rt2800usb into Linux 2.6.27 ?
(Journeyer J. Joh)
2. Re: How can I backport rt2800usb into Linux 2.6.27 ?
(Journeyer J. Joh)
3. [PATCH v3 1/2] rt2x00: rt2800lib: add rt2800_hw_beacon_base
helper (Gabor Juhos)
4. [PATCH v3 2/2] rt2x00: rt2800lib: don't hardcode beacon
offsets (Gabor Juhos)
----------------------------------------------------------------------
Message: 1
Date: Thu, 22 Aug 2013 14:04:01 +0900
From: "Journeyer J. Joh" <[email protected]>
To: Helmut Schaa <[email protected]>
Cc: rt2x00 Users List <[email protected]>
Subject: Re: [rt2x00-users] How can I backport rt2800usb into Linux
2.6.27 ?
Message-ID:
<calykt1js17pnwhutxcdjpria9jmady6tuuxapzc_spehu03...@mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"
Hi Helmut Schaa and people on our list,
Thank you for your letting me know about the backports project.
But I cannot use it because I don't know what am I supposed to handle this
project.
When I menuconfig and checked I need I can compile several .ko files shown
below.
./drivers/net/wireless/rt2x00/rt2800usb.ko
./drivers/net/wireless/rt2x00/rt2x00usb.ko
./drivers/net/wireless/rt2x00/rt2800lib.ko
./drivers/net/wireless/rt2x00/rt2x00lib.ko
./net/wireless/cfg80211.ko
./net/mac80211/mac80211.ko
./compat/compat.ko
But these are natively compiled for x86.
I need one for arm 32bit. for my arm cross compiler.
1. I'd like to know how I can cross compile this.
Yes there is a guide on the document but it's not enough. I want some
examples.
Like the one I compile my linux kernel as shown below.
make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
menuconfig
make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
uImage
make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
modules
2. I wonder if this compiled kernel objects are right for my kernel version
- 2.6.27.
*A backports-3.x release means device drivers from the Linux v3.x release
have been taken, backported and made available for you to use on any kernel
you may be on from 2.6.24 - 3.(x-1).*
3. If I successfully cross-compiled this am I just supposed to place it
into my target embedded system?
4. There is one - compat.ko - outstanding to me. Does this have all the
magic of compatibiity? So I must insmod?
Sincerely
Journeyer
I am learning while I am writing questions....
----------------------------------------
Journeyer J. Joh
o o s a p r o g r a m m e r
a t
g m a i l d o t c o m
----------------------------------------
2013/8/21 Helmut Schaa <[email protected]>
> On Wed, Aug 21, 2013 at 7:26 AM, Journeyer J. Joh
> <[email protected]> wrote:
> > Hi,
> >
> > I'd like to use RT5370 WiFi module on my target embeded system.
> > The linux on the system is 2.6.27 and I believe it is uClinux.
> >
> > memuconfig only includes rt2500usb and rt2500lib not rt2800usb.
> >
> > 1. I'd like to know where I can get the source code for rt2800usb.
> > 2. Is there any known method for me to backport rt2800usb on my linux
> > 2.6.27?
> >
> > Thank you very much in advance.
>
> You might want to try compat-drivers:
> https://backports.wiki.kernel.org/index.php/Documentation
>
> Helmut
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rt2x00.serialmonkey.com/pipermail/users_rt2x00.serialmonkey.com/attachments/20130822/7b820ac1/attachment-0001.html>
------------------------------
Message: 2
Date: Thu, 22 Aug 2013 14:19:13 +0900
From: "Journeyer J. Joh" <[email protected]>
To: Helmut Schaa <[email protected]>
Cc: rt2x00 Users List <[email protected]>
Subject: Re: [rt2x00-users] How can I backport rt2800usb into Linux
2.6.27 ?
Message-ID:
<calykt1jjsg6zkewwwawy2ko0batszzkg0su6an9a9dm68ty...@mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"
I am sorry.
I mistakenly sent this question to rt2x00 maillist.
This question has to be sent to backports maillist.
I am so sorry for this.
Thanks everyone.
Regards
Journeyer
----------------------------------------
Journeyer J. Joh
o o s a p r o g r a m m e r
a t
g m a i l d o t c o m
----------------------------------------
2013/8/22 Journeyer J. Joh <[email protected]>
> Hi Helmut Schaa and people on our list,
>
> Thank you for your letting me know about the backports project.
> But I cannot use it because I don't know what am I supposed to handle this
> project.
>
> When I menuconfig and checked I need I can compile several .ko files shown
> below.
>
> ./drivers/net/wireless/rt2x00/rt2800usb.ko
> ./drivers/net/wireless/rt2x00/rt2x00usb.ko
> ./drivers/net/wireless/rt2x00/rt2800lib.ko
> ./drivers/net/wireless/rt2x00/rt2x00lib.ko
> ./net/wireless/cfg80211.ko
> ./net/mac80211/mac80211.ko
> ./compat/compat.ko
>
> But these are natively compiled for x86.
>
> I need one for arm 32bit. for my arm cross compiler.
>
> 1. I'd like to know how I can cross compile this.
> Yes there is a guide on the document but it's not enough. I want some
> examples.
> Like the one I compile my linux kernel as shown below.
>
> make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
> menuconfig
> make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
> uImage
> make ARCH=arm CROSS_COMPILE=/opt/arm-2007q1/bin/arm-none-linux-gnueabi-
> modules
>
> 2. I wonder if this compiled kernel objects are right for my kernel
> version - 2.6.27.
> *A backports-3.x release means device drivers from the Linux v3.x release
> have been taken, backported and made available for you to use on any kernel
> you may be on from 2.6.24 - 3.(x-1).*
>
> 3. If I successfully cross-compiled this am I just supposed to place it
> into my target embedded system?
>
> 4. There is one - compat.ko - outstanding to me. Does this have all the
> magic of compatibiity? So I must insmod?
>
> Sincerely
> Journeyer
>
> I am learning while I am writing questions....
>
>
> ----------------------------------------
> Journeyer J. Joh
> o o s a p r o g r a m m e r
> a t
> g m a i l d o t c o m
> ----------------------------------------
>
>
> 2013/8/21 Helmut Schaa <[email protected]>
>
>> On Wed, Aug 21, 2013 at 7:26 AM, Journeyer J. Joh
>> <[email protected]> wrote:
>> > Hi,
>> >
>> > I'd like to use RT5370 WiFi module on my target embeded system.
>> > The linux on the system is 2.6.27 and I believe it is uClinux.
>> >
>> > memuconfig only includes rt2500usb and rt2500lib not rt2800usb.
>> >
>> > 1. I'd like to know where I can get the source code for rt2800usb.
>> > 2. Is there any known method for me to backport rt2800usb on my linux
>> > 2.6.27?
>> >
>> > Thank you very much in advance.
>>
>> You might want to try compat-drivers:
>> https://backports.wiki.kernel.org/index.php/Documentation
>>
>> Helmut
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rt2x00.serialmonkey.com/pipermail/users_rt2x00.serialmonkey.com/attachments/20130822/4ce2d984/attachment-0001.html>
------------------------------
Message: 3
Date: Thu, 22 Aug 2013 20:53:21 +0200
From: Gabor Juhos <[email protected]>
To: "John W. Linville" <[email protected]>
Cc: Gabor Juhos <[email protected]>, [email protected],
[email protected]
Subject: [rt2x00-users] [PATCH v3 1/2] rt2x00: rt2800lib: add
rt2800_hw_beacon_base helper
Message-ID: <[email protected]>
The HW_BEACON_BASE() macro returns the base address
of a given beacon, however the returned values are
not usable on all chipsets. On devices which have
selectable shared memory parts, some beacon may be
located in the high part of the shared memory.
Instead of extending the already complicated macro,
add a new helper function and use that to get the
base address of a given beacon.
The actual patch contains no functional changes, the
helper function will be extended in a further patch
to handle different chipsets' requirements.
Signed-off-by: Gabor Juhos <[email protected]>
---
Changes since v2:
- separated from the 'rt2x00: fix beaconing on RT3593' patch-set
- update commit log
Changes since v1: ---
---
drivers/net/wireless/rt2x00/rt2800lib.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c
b/drivers/net/wireless/rt2x00/rt2800lib.c
index aa6b6b0..38606e2 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -940,6 +940,12 @@ void rt2800_txdone_entry(struct queue_entry *entry, u32
status, __le32 *txwi)
}
EXPORT_SYMBOL_GPL(rt2800_txdone_entry);
+static unsigned int rt2800_hw_beacon_base(struct rt2x00_dev *rt2x00dev,
+ unsigned int index)
+{
+ return HW_BEACON_BASE(index);
+}
+
void rt2800_write_beacon(struct queue_entry *entry, struct txentry_desc
*txdesc)
{
struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
@@ -992,7 +998,8 @@ void rt2800_write_beacon(struct queue_entry *entry, struct
txentry_desc *txdesc)
return;
}
- beacon_base = HW_BEACON_BASE(entry->entry_idx);
+ beacon_base = rt2800_hw_beacon_base(rt2x00dev, entry->entry_idx);
+
rt2800_register_multiwrite(rt2x00dev, beacon_base, entry->skb->data,
entry->skb->len + padding_len);
@@ -1017,7 +1024,7 @@ static inline void rt2800_clear_beacon_register(struct
rt2x00_dev *rt2x00dev,
const int txwi_desc_size = rt2x00dev->bcn->winfo_size;
unsigned int beacon_base;
- beacon_base = HW_BEACON_BASE(index);
+ beacon_base = rt2800_hw_beacon_base(rt2x00dev, index);
/*
* For the Beacon base registers we only need to clear
--
1.7.10
------------------------------
Message: 4
Date: Thu, 22 Aug 2013 20:53:22 +0200
From: Gabor Juhos <[email protected]>
To: "John W. Linville" <[email protected]>
Cc: Gabor Juhos <[email protected]>, [email protected],
[email protected]
Subject: [rt2x00-users] [PATCH v3 2/2] rt2x00: rt2800lib: don't
hardcode beacon offsets
Message-ID: <[email protected]>
The values written into the BCN_OFFSET[01] registers are
hardcoded in the rt2800_init_register function.
Add a macro and a helper function to derive these values
directly from the base address of a given beacon, and use
the new function instead of the hardcoded numbers.
The patch contains no functional changes. The programmed
register values are the same before and after the patch.
Signed-off-by: Gabor Juhos <[email protected]>
---
Changes since v2:
- separated from the 'rt2x00: fix beaconing on RT3593' patch-set
Changes since v1: ---
---
drivers/net/wireless/rt2x00/rt2800.h | 2 ++
drivers/net/wireless/rt2x00/rt2800lib.c | 30 ++++++++++++++++++++++--------
2 files changed, 24 insertions(+), 8 deletions(-)
diff --git a/drivers/net/wireless/rt2x00/rt2800.h
b/drivers/net/wireless/rt2x00/rt2800.h
index e25e5bf..fa33b5e 100644
--- a/drivers/net/wireless/rt2x00/rt2800.h
+++ b/drivers/net/wireless/rt2x00/rt2800.h
@@ -2024,6 +2024,8 @@ struct mac_iveiv_entry {
(((__index) < 6) ? (HW_BEACON_BASE4 + ((__index - 4) * 0x0200)) : \
(HW_BEACON_BASE6 - ((__index - 6) * 0x0200))))
+#define BEACON_BASE_TO_OFFSET(_base) (((_base) - 0x4000) / 64)
+
/*
* BBP registers.
* The wordsize of the BBP is 8 bits.
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c
b/drivers/net/wireless/rt2x00/rt2800lib.c
index 38606e2..20243dc 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -946,6 +946,12 @@ static unsigned int rt2800_hw_beacon_base(struct
rt2x00_dev *rt2x00dev,
return HW_BEACON_BASE(index);
}
+static inline u8 rt2800_get_beacon_offset(struct rt2x00_dev *rt2x00dev,
+ unsigned int index)
+{
+ return BEACON_BASE_TO_OFFSET(rt2800_hw_beacon_base(rt2x00dev, index));
+}
+
void rt2800_write_beacon(struct queue_entry *entry, struct txentry_desc
*txdesc)
{
struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
@@ -4474,17 +4480,25 @@ static int rt2800_init_registers(struct rt2x00_dev
*rt2x00dev)
return ret;
rt2800_register_read(rt2x00dev, BCN_OFFSET0, ®);
- rt2x00_set_field32(®, BCN_OFFSET0_BCN0, 0xe0); /* 0x3800 */
- rt2x00_set_field32(®, BCN_OFFSET0_BCN1, 0xe8); /* 0x3a00 */
- rt2x00_set_field32(®, BCN_OFFSET0_BCN2, 0xf0); /* 0x3c00 */
- rt2x00_set_field32(®, BCN_OFFSET0_BCN3, 0xf8); /* 0x3e00 */
+ rt2x00_set_field32(®, BCN_OFFSET0_BCN0,
+ rt2800_get_beacon_offset(rt2x00dev, 0));
+ rt2x00_set_field32(®, BCN_OFFSET0_BCN1,
+ rt2800_get_beacon_offset(rt2x00dev, 1));
+ rt2x00_set_field32(®, BCN_OFFSET0_BCN2,
+ rt2800_get_beacon_offset(rt2x00dev, 2));
+ rt2x00_set_field32(®, BCN_OFFSET0_BCN3,
+ rt2800_get_beacon_offset(rt2x00dev, 3));
rt2800_register_write(rt2x00dev, BCN_OFFSET0, reg);
rt2800_register_read(rt2x00dev, BCN_OFFSET1, ®);
- rt2x00_set_field32(®, BCN_OFFSET1_BCN4, 0xc8); /* 0x3200 */
- rt2x00_set_field32(®, BCN_OFFSET1_BCN5, 0xd0); /* 0x3400 */
- rt2x00_set_field32(®, BCN_OFFSET1_BCN6, 0x77); /* 0x1dc0 */
- rt2x00_set_field32(®, BCN_OFFSET1_BCN7, 0x6f); /* 0x1bc0 */
+ rt2x00_set_field32(®, BCN_OFFSET1_BCN4,
+ rt2800_get_beacon_offset(rt2x00dev, 4));
+ rt2x00_set_field32(®, BCN_OFFSET1_BCN5,
+ rt2800_get_beacon_offset(rt2x00dev, 5));
+ rt2x00_set_field32(®, BCN_OFFSET1_BCN6,
+ rt2800_get_beacon_offset(rt2x00dev, 6));
+ rt2x00_set_field32(®, BCN_OFFSET1_BCN7,
+ rt2800_get_beacon_offset(rt2x00dev, 7));
rt2800_register_write(rt2x00dev, BCN_OFFSET1, reg);
rt2800_register_write(rt2x00dev, LEGACY_BASIC_RATE, 0x0000013f);
--
1.7.10
------------------------------
Subject: Digest Footer
_______________________________________________
users mailing list
[email protected]
http://rt2x00.serialmonkey.com/mailman/listinfo/users_rt2x00.serialmonkey.com
------------------------------
End of users Digest, Vol 54, Issue 14
*************************************