public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
@ 2008-04-22 12:18 Jens Gehrlein
  2008-04-22 18:03 ` Ben Warren
  0 siblings, 1 reply; 7+ messages in thread
From: Jens Gehrlein @ 2008-04-22 12:18 UTC (permalink / raw)
  To: u-boot

Hi,

in the source code there is a preprocessor directive
#error "SMC911X: Only 32-bit bus is supported".

We use a LAN9215i, which has a 16 Bit data interface only, connected to 
an i.MX31.

The LAN9215 is in the driver's ID list.

According to the data sheet accesses have to be 2x16 Bit to build the 
device's internal 32 Bit format.

What does this non-32-Bit exclusion exactly mean?
Will the driver work on our HW configuration?

Confused,
Jens

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-22 12:18 [U-Boot-Users] Question about smc911x driver (16/32 Bit support) Jens Gehrlein
@ 2008-04-22 18:03 ` Ben Warren
  2008-04-23  6:37   ` Jens Gehrlein
  0 siblings, 1 reply; 7+ messages in thread
From: Ben Warren @ 2008-04-22 18:03 UTC (permalink / raw)
  To: u-boot

Hi Jens,

On Tue, Apr 22, 2008 at 5:18 AM, Jens Gehrlein <sew_s@tqs.de> wrote:
> Hi,
>
>  in the source code there is a preprocessor directive
>  #error "SMC911X: Only 32-bit bus is supported".
>
>  We use a LAN9215i, which has a 16 Bit data interface only, connected to
>  an i.MX31.
>
>  The LAN9215 is in the driver's ID list.
>
>  According to the data sheet accesses have to be 2x16 Bit to build the
>  device's internal 32 Bit format.
>
>  What does this non-32-Bit exclusion exactly mean?
>  Will the driver work on our HW configuration?
>
This #error message was included, because if you look at the code
you'll see that the read/write accessors are 32-bit operations *(u32 *
).  These may or may not work on your configuration.  It should be
trivial to write accessors for a 16-bit bus, but nobody had hardware
to try it out on.  Please do so and submit a patch.

>  Confused,
>  Jens

regards,
Ben

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-22 18:03 ` Ben Warren
@ 2008-04-23  6:37   ` Jens Gehrlein
  2008-04-23 13:35     ` Magnus Lilja
  0 siblings, 1 reply; 7+ messages in thread
From: Jens Gehrlein @ 2008-04-23  6:37 UTC (permalink / raw)
  To: u-boot

Hi Ben,

Ben Warren schrieb:
> Hi Jens,
> 
> On Tue, Apr 22, 2008 at 5:18 AM, Jens Gehrlein <sew_s@tqs.de> wrote:
>> Hi,
>>
>>  in the source code there is a preprocessor directive
>>  #error "SMC911X: Only 32-bit bus is supported".
>>
>>  We use a LAN9215i, which has a 16 Bit data interface only, connected to
>>  an i.MX31.
>>
>>  The LAN9215 is in the driver's ID list.
>>
>>  According to the data sheet accesses have to be 2x16 Bit to build the
>>  device's internal 32 Bit format.
>>
>>  What does this non-32-Bit exclusion exactly mean?
>>  Will the driver work on our HW configuration?
>>
> This #error message was included, because if you look at the code
> you'll see that the read/write accessors are 32-bit operations *(u32 *
> ).  These may or may not work on your configuration.  It should be
> trivial to write accessors for a 16-bit bus, but nobody had hardware
> to try it out on.  Please do so and submit a patch.

Yes, it seems, that we just need two additional functions which split a 
32 Bit access into two 16 Bit accesses. That should be easy. I'm going 
to create a patch as soon as I get the HW. But first I want to test 
whether the processor splits itself automatically.

Thank you very much.

Best Regards,
Jens

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-23  6:37   ` Jens Gehrlein
@ 2008-04-23 13:35     ` Magnus Lilja
  2008-04-23 17:29       ` Ben Warren
  0 siblings, 1 reply; 7+ messages in thread
From: Magnus Lilja @ 2008-04-23 13:35 UTC (permalink / raw)
  To: u-boot

Hi Jens,

On Wed, Apr 23, 2008 at 8:37 AM, Jens Gehrlein <sew_s@tqs.de> wrote:
>  >>  in the source code there is a preprocessor directive
>  >>  #error "SMC911X: Only 32-bit bus is supported".
>  >>
>  >>  We use a LAN9215i, which has a 16 Bit data interface only, connected to
>  >>  an i.MX31.
>  >>
>  >>  The LAN9215 is in the driver's ID list.
>  >>
>  >>  According to the data sheet accesses have to be 2x16 Bit to build the
>  >>  device's internal 32 Bit format.
>  >>
>  >>  What does this non-32-Bit exclusion exactly mean?
>  >>  Will the driver work on our HW configuration?
>  >>
>  > This #error message was included, because if you look at the code
>  > you'll see that the read/write accessors are 32-bit operations *(u32 *
>  > ).  These may or may not work on your configuration.  It should be
>  > trivial to write accessors for a 16-bit bus, but nobody had hardware
>  > to try it out on.  Please do so and submit a patch.
>
>  Yes, it seems, that we just need two additional functions which split a
>  32 Bit access into two 16 Bit accesses. That should be easy. I'm going
>  to create a patch as soon as I get the HW. But first I want to test
>  whether the processor splits itself automatically.

Well, the i.MX31 Litekit board has a 16-bit LAN9117 and that seems to
work with the 32-bit flag set in the config file.

/Magnus

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-23 13:35     ` Magnus Lilja
@ 2008-04-23 17:29       ` Ben Warren
  2008-04-23 17:53         ` Magnus Lilja
  0 siblings, 1 reply; 7+ messages in thread
From: Ben Warren @ 2008-04-23 17:29 UTC (permalink / raw)
  To: u-boot

Hi Magnus,

On Wed, Apr 23, 2008 at 6:35 AM, Magnus Lilja <lilja.magnus@gmail.com> wrote:
> Hi Jens,
>
>  On Wed, Apr 23, 2008 at 8:37 AM, Jens Gehrlein <sew_s@tqs.de> wrote:
>  >  >>  in the source code there is a preprocessor directive
>  >  >>  #error "SMC911X: Only 32-bit bus is supported".
>  >  >>
>  >  >>  We use a LAN9215i, which has a 16 Bit data interface only, connected to
>  >  >>  an i.MX31.
>  >  >>
>  >  >>  The LAN9215 is in the driver's ID list.
>  >  >>
>  >  >>  According to the data sheet accesses have to be 2x16 Bit to build the
>  >  >>  device's internal 32 Bit format.
>  >  >>
>  >  >>  What does this non-32-Bit exclusion exactly mean?
>  >  >>  Will the driver work on our HW configuration?
>  >  >>
>  >  > This #error message was included, because if you look at the code
>  >  > you'll see that the read/write accessors are 32-bit operations *(u32 *
>  >  > ).  These may or may not work on your configuration.  It should be
>  >  > trivial to write accessors for a 16-bit bus, but nobody had hardware
>  >  > to try it out on.  Please do so and submit a patch.
>  >
>  >  Yes, it seems, that we just need two additional functions which split a
>  >  32 Bit access into two 16 Bit accesses. That should be easy. I'm going
>  >  to create a patch as soon as I get the HW. But first I want to test
>  >  whether the processor splits itself automatically.
>
>  Well, the i.MX31 Litekit board has a 16-bit LAN9117 and that seems to
>  work with the 32-bit flag set in the config file.
>
That's good news.  I would prefer, though, to break this into two
16-bit accesses so we don't need to wonder what architectures it would
work on.  Would you be able to try something out, since you have
hardware?

regards,
Ben

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-23 17:29       ` Ben Warren
@ 2008-04-23 17:53         ` Magnus Lilja
  2008-04-25 11:22           ` Jens Gehrlein
  0 siblings, 1 reply; 7+ messages in thread
From: Magnus Lilja @ 2008-04-23 17:53 UTC (permalink / raw)
  To: u-boot

Hi Ben,

>  >  Well, the i.MX31 Litekit board has a 16-bit LAN9117 and that seems to
>  >  work with the 32-bit flag set in the config file.
>  >
>  That's good news.  I would prefer, though, to break this into two
>  16-bit accesses so we don't need to wonder what architectures it would
>  work on.  Would you be able to try something out, since you have
>  hardware?

If someone publishes a patch I can certainly try it on the hardware.

Regards, Magnus

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot-Users] Question about smc911x driver (16/32 Bit support)
  2008-04-23 17:53         ` Magnus Lilja
@ 2008-04-25 11:22           ` Jens Gehrlein
  0 siblings, 0 replies; 7+ messages in thread
From: Jens Gehrlein @ 2008-04-25 11:22 UTC (permalink / raw)
  To: u-boot

Hi Magnus, Ben,

Magnus Lilja schrieb:
> Hi Ben,
> 
>>  >  Well, the i.MX31 Litekit board has a 16-bit LAN9117 and that seems to
>>  >  work with the 32-bit flag set in the config file.
>>  >
>>  That's good news.  I would prefer, though, to break this into two
>>  16-bit accesses so we don't need to wonder what architectures it would
>>  work on.  Would you be able to try something out, since you have
>>  hardware?
> 
> If someone publishes a patch I can certainly try it on the hardware.

I already prepared the patch, but currently I can't test it, and I'm not 
sure if I did it right. Please be patient.
Meanwhile, I report successful execution of the current driver yesterday 
on our HW developer's board with 16 bit port size. The i.MX31 splits the 
32 bit word (I knew that from PowerPC, but wasn't sure of ARM).

Regards,
Jens

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-04-25 11:22 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-22 12:18 [U-Boot-Users] Question about smc911x driver (16/32 Bit support) Jens Gehrlein
2008-04-22 18:03 ` Ben Warren
2008-04-23  6:37   ` Jens Gehrlein
2008-04-23 13:35     ` Magnus Lilja
2008-04-23 17:29       ` Ben Warren
2008-04-23 17:53         ` Magnus Lilja
2008-04-25 11:22           ` Jens Gehrlein

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox