Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-06 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message <4c8521a8.6050...@free.fr> you wrote: > > I don't see much benefit in allocating dynamically rather than > statically unless you are really tight on RAM, which seems to not fit > with a board which has many busses and disks. > > Plus, IDE may not know about hotp

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-06 Thread Albert ARIBAUD
Le 06/09/2010 14:50, Wolfgang Denk a écrit : >> 2) as for ide_bus_offset[] and ide_dev_desc[], and any other existing >> array based on CONFIG_SYS_IDE_MAXBUS or CONFIG_SYS_IDE_MAXDEVICE, they >> are not going to grow any bigger with my proposal since neither config >> option will increase. > > We

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-06 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message <4c84d13c.8040...@free.fr> you wrote: > > Er... no, it isn't. cmd_ide can support no more than two busses, the > offsets of which are defined by CONFIG_SYS_ATA_IDE0_OFFSET, and optional > CONFIG_SYS_ATA_IDE1_OFFSET if CONFIG_SYS_IDE_MAXBUS > 0 (note that these >

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-06 Thread Albert ARIBAUD
Le 06/09/2010 10:18, Wolfgang Denk a écrit : > I don't understand what you want to tell me. As far as PATA is > concerned (and this is all what "*_IDE_*" config options refer to), > we can have zero, one or two devices per bus, and the code supports > this. > > For systems, where only one device c

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-06 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message <4c848e1a.1070...@free.fr> you wrote: > > >> Indeed; and additionally, who says you can only have two IDE busses? I > >> am facing the case right now with the MV88SX6081, which is an 8-ports > >> controller. > > > > But this is NOT an PATA controller, right? > > C

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Albert ARIBAUD
Hi again Wolfgang, Le 06/09/2010 08:05, Wolfgang Denk a écrit : > Dear Albert ARIBAUD, > > In message<4c848200.7080...@free.fr> you wrote: >> >>> First, CONFIG_SYS_IDE_* is for "IDE" (aka "Integrated Drive >>> Electronics"), now usually references as "Parallel ATA", as defined >>> by the underlyi

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message <4c848200.7080...@free.fr> you wrote: > > > First, CONFIG_SYS_IDE_* is for "IDE" (aka "Integrated Drive > > Electronics"), now usually references as "Parallel ATA", as defined > > by the underlying AT Attachment (ATA) and AT Attachment Packet > > Interface (ATAPI) s

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Rogan Dawes
On 2010/09/06 7:54 AM, Albert ARIBAUD wrote: > /* OpenRD's two kirkwood busses are SATA: 1 device per bux max) */ > #define CONFIG_SYS_ATA_IDE_CONFIG { \ > { KW_SATA_PORT0_OFFSET, 1}, \ > { KW_SATA_PORT1_OFFSET, 1} \ > } > I like this, as it removes assumptions from the code. FWIW.

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Albert ARIBAUD
Hi Wolfgang, Le 06/09/2010 00:19, Wolfgang Denk a écrit : > Dear Albert ARIBAUD, > > In message<4c8201cb.9080...@free.fr> you wrote: >> >> I think that, rather than modifying IDE_BUS(dev), you should introduce a >> CONFIG_SYS_IDE_MAXDEVICE_PER_BUS config option that will limit how many >> devices

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message <4c8201cb.9080...@free.fr> you wrote: > > I think that, rather than modifying IDE_BUS(dev), you should introduce a > CONFIG_SYS_IDE_MAXDEVICE_PER_BUS config option that will limit how many > devices will be probed for on a given bus. > Without this config option, f

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-05 Thread Rogan Dawes
On 2010/09/04 11:07 AM, Albert ARIBAUD wrote: > Le 04/09/2010 10:22, Albert ARIBAUD a écrit : >> Le 26/08/2010 15:16, Rogan Dawes a écrit : >> >>> Anything wrong with this patch? >> >> I think I finally found what was bugging me with it. >> >> Granted, there are cases where we don't want two device

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-04 Thread Albert ARIBAUD
Le 04/09/2010 10:22, Albert ARIBAUD a écrit : > Le 26/08/2010 15:16, Rogan Dawes a écrit : > >> Anything wrong with this patch? > > I think I finally found what was bugging me with it. > > Granted, there are cases where we don't want two devices per bus, but > this is a requirement unrelated to the

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-09-04 Thread Albert ARIBAUD
Le 26/08/2010 15:16, Rogan Dawes a écrit : > Anything wrong with this patch? I think I finally found what was bugging me with it. Granted, there are cases where we don't want two devices per bus, but this is a requirement unrelated to the maximum number of busses and devices: this is simply du

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-08-26 Thread Rogan Dawes
On 2010/08/16 7:47 AM, Rogan Dawes wrote: > From: Rogan Dawes > > Some SATA controllers can operate in an IDE compatible mode (e.g. mvsata) > but will only ever have a single device per bus. > > This allows the upcoming DNS323 port to properly identify and use > a drive on both SATA interfaces.

[U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-08-15 Thread Rogan Dawes
From: Rogan Dawes Some SATA controllers can operate in an IDE compatible mode (e.g. mvsata) but will only ever have a single device per bus. This allows the upcoming DNS323 port to properly identify and use a drive on both SATA interfaces. --- include/ide.h |3 ++- 1 files changed, 2 insert

Re: [U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-08-15 Thread Wolfgang Denk
Dear Rogan Dawes, In message <1281904542-11694-1-git-send-email-ro...@dawes.za.net> you wrote: > > -#define IDE_BUS(dev)(dev >> 1) > +#define IDE_BUS(dev)(dev >> (CONFIG_SYS_IDE_MAXDEVICE / \ > + CONFIG_SYS_IDE_MAXBUS - 1)) Please add parens to make c

[U-Boot] [PATCH] IDE: Don't assume there are always two devices per bus

2010-08-15 Thread Rogan Dawes
Some SATA controllers can operate in an IDE compatible mode (e.g. mvsata) but will only ever have a single device per bus. This allows the upcoming DNS323 port to properly identify and use a drive on both SATA interfaces. --- include/ide.h |3 ++- 1 files changed, 2 insertions(+), 1 deletions