* Mounting CF flash card in 2.6.25
@ 2008-06-03 2:06 vb
2008-06-03 15:41 ` vb
2008-06-03 16:19 ` Alan Cox
0 siblings, 2 replies; 7+ messages in thread
From: vb @ 2008-06-03 2:06 UTC (permalink / raw)
To: linux-ide
Hello linux-ide people,
I am trying to bring up a system with a CF card (wired in True IDE
mode) on a powerpc platform under 2.6.25 control.
The following flags are enabled in the config (among many others, naturally):
CONFIG_SCSI=y
CONFIG_SCSI_DMA=y
CONFIG_SCSI_PROC_FS=y
CONFIG_SCSI_WAIT_SCAN=m
CONFIG_SCSI_LOWLEVEL=y
CONFIG_PATA_PLATFORM=y
CONFIG_PATA_OF_PLATFORM=y
I am trying to bring up a system initrd, as I have a CF card installed
with the appropriate userland on it. When the kernel boots up I see
the following (again, along with a lot of other stuff):
scsi0 : pata_platform
ata1: PATA max PIO6 mmio cmd 0xfc000000 ctl 0xfc00020c irq 20
ata1.00: CFA: CF 512MB, 06/07/29, max PIO4
ata1.00: 1028160 sectors, multi 0: LBA
ata1.00: configured for PIO
ata1.00: configured for PIO
ata1: EH complete
scsi 0:0:0:0: Direct-Access ATA CF 512MB 06/0 PQ: 0 ANSI: 5
which tells me that the card is being recognized. However, there is no
appropriate device get created in the /dev directory. Examining
major_names[] I see that only
ramdisk
loop
mtdblock
are created, but there is nothing of the kind /dev/{ata,scsi,ide}, so
attempts to mount the CF fail.
I must be missing something very basic, but I just can't get what it
is, and don't seem to be able to find any documentation on how this is
supposed to work.
I see that there are drivers for CF cards in
drivers/ata/pata_{pcmcia,rb500_cf,ixp4xx_cf}.c, but I was under
impression that the one in pata_of_platform is supposed to do for a
generic CF card.
What needs to be done to get the device created and mapped to a
generic CF card?
I would really appreciate any hints here, as this thing makes me
slowly lose the remains of the sanity I once had:-)
Thank you in advance,
Vadim
PS. And I promise to write a Wiki page or HOWTO once this issue is resolved.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 2:06 Mounting CF flash card in 2.6.25 vb
@ 2008-06-03 15:41 ` vb
2008-06-03 16:19 ` Alan Cox
1 sibling, 0 replies; 7+ messages in thread
From: vb @ 2008-06-03 15:41 UTC (permalink / raw)
To: linux-ide
>
> I am trying to bring up a system initrd, as I have a CF card installed
sorry, this of course should read "I am trying to bring up a system
*without* initrd".
I start wondering if anyone ever had a generic CF card working in 2.6.25...
cheers,
/vb
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 2:06 Mounting CF flash card in 2.6.25 vb
2008-06-03 15:41 ` vb
@ 2008-06-03 16:19 ` Alan Cox
2008-06-03 16:48 ` vb
1 sibling, 1 reply; 7+ messages in thread
From: Alan Cox @ 2008-06-03 16:19 UTC (permalink / raw)
To: vb; +Cc: linux-ide
> scsi0 : pata_platform
> ata1: PATA max PIO6 mmio cmd 0xfc000000 ctl 0xfc00020c irq 20
> ata1.00: CFA: CF 512MB, 06/07/29, max PIO4
> ata1.00: 1028160 sectors, multi 0: LBA
> ata1.00: configured for PIO
> ata1.00: configured for PIO
> ata1: EH complete
> scsi 0:0:0:0: Direct-Access ATA CF 512MB 06/0 PQ: 0 ANSI: 5
>
>
> which tells me that the card is being recognized. However, there is no
> appropriate device get created in the /dev directory. Examining
The /dev creation is up to your initrd.
> impression that the one in pata_of_platform is supposed to do for a
> generic CF card.
In your case it seems to be correct.
> What needs to be done to get the device created and mapped to a
> generic CF card?
You need to ensure you have SCSI_DISK support included (as CF is a disk)
and you need your initrd either to create device nodes, or to prepack
them.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 16:19 ` Alan Cox
@ 2008-06-03 16:48 ` vb
2008-06-03 17:34 ` Michael Tokarev
0 siblings, 1 reply; 7+ messages in thread
From: vb @ 2008-06-03 16:48 UTC (permalink / raw)
To: Alan Cox; +Cc: linux-ide
Alan,
thank you for your reply, I am not quite clear with a couple of things
though, please see below:
On Tue, Jun 3, 2008 at 9:19 AM, Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
>>
>> which tells me that the card is being recognized. However, there is no
>> appropriate device get created in the /dev directory. Examining
>
> The /dev creation is up to your initrd.
>
but I don't have initrd, so I need the kernel to create /dev/<drive>.
It does create other devices, right?
>> What needs to be done to get the device created and mapped to a
>> generic CF card?
>
> You need to ensure you have SCSI_DISK support included (as CF is a disk)
> and you need your initrd either to create device nodes, or to prepack
> them.
>
I don't see SCSI_DISK as a config option, can you please elaborate on this?
TIA,
/vb
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 16:48 ` vb
@ 2008-06-03 17:34 ` Michael Tokarev
2008-06-03 17:49 ` vb
2008-06-03 18:13 ` vb
0 siblings, 2 replies; 7+ messages in thread
From: Michael Tokarev @ 2008-06-03 17:34 UTC (permalink / raw)
To: vb; +Cc: Alan Cox, linux-ide
vb wrote:
> Alan,
>
> thank you for your reply, I am not quite clear with a couple of things
> though, please see below:
>
> On Tue, Jun 3, 2008 at 9:19 AM, Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
>>> which tells me that the card is being recognized. However, there is no
>>> appropriate device get created in the /dev directory. Examining
>> The /dev creation is up to your initrd.
>
> but I don't have initrd, so I need the kernel to create /dev/<drive>.
> It does create other devices, right?
Kernel does not maintain /dev, ever. Times of devfs are long gone.
All nodes in your /dev are created in userspace.
>>> What needs to be done to get the device created and mapped to a
>>> generic CF card?
>> You need to ensure you have SCSI_DISK support included (as CF is a disk)
>> and you need your initrd either to create device nodes, or to prepack
>> them.
>
> I don't see SCSI_DISK as a config option, can you please elaborate on this?
It's CONFIG_BLK_DEV_SD.
/mjt
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 17:34 ` Michael Tokarev
@ 2008-06-03 17:49 ` vb
2008-06-03 18:13 ` vb
1 sibling, 0 replies; 7+ messages in thread
From: vb @ 2008-06-03 17:49 UTC (permalink / raw)
To: Michael Tokarev; +Cc: linux-ide
Michael, thank you for your reply and pardon my ignorance,
On Tue, Jun 3, 2008 at 10:34 AM, Michael Tokarev <mjt@tls.msk.ru> wrote:
> Kernel does not maintain /dev, ever. Times of devfs are long gone.
> All nodes in your /dev are created in userspace.
>
but I see that the kernel creates /dev/ram[0..15],
/dev/mtdblock[0..3], at least I see these mentioned in
block/genhd.c:major_names[] - are these not devices created by kernel?
Are you saying that I can't mount a CF card without initrd (or nfs
mounted userland, etc.)?
>>>> What needs to be done to get the device created and mapped to a
>>>> generic CF card?
>>>
>>> You need to ensure you have SCSI_DISK support included (as CF is a disk)
>>> and you need your initrd either to create device nodes, or to prepack
>>> them.
>>
>> I don't see SCSI_DISK as a config option, can you please elaborate on
>> this?
>
> It's CONFIG_BLK_DEV_SD.
>
thank you for the hint, let me try this...
cheers,
/vb
> /mjt
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Mounting CF flash card in 2.6.25
2008-06-03 17:34 ` Michael Tokarev
2008-06-03 17:49 ` vb
@ 2008-06-03 18:13 ` vb
1 sibling, 0 replies; 7+ messages in thread
From: vb @ 2008-06-03 18:13 UTC (permalink / raw)
To: Michael Tokarev, Alan Cox; +Cc: linux-ide
On Tue, Jun 3, 2008 at 10:34 AM, Michael Tokarev <mjt@tls.msk.ru> wrote:
> vb wrote:
>> On Tue, Jun 3, 2008 at 9:19 AM, Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
>>>
>>> You need to ensure you have SCSI_DISK support included (as CF is a disk)
>>> and you need your initrd either to create device nodes, or to prepack
>>> them.
>>
>> I don't see SCSI_DISK as a config option, can you please elaborate on
>> this?
>
> It's CONFIG_BLK_DEV_SD.
>
Alan, Michael, this was it - now the /dev/sda and friends get created,
the CF gets mounted and the system comes up all the way to the login
prompt!
Thank you so much for your help, (and for my faith in free software
being restored :-))
What do you think: shouldn't enabling of PATA_OF_PLATFORM enable
BLK_DEV_SD automatically? This would have saved me (and maybe a few
more newbies who try doing this) a few days of banging my head against
the desk.
regards,
Vadim
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2008-06-03 18:13 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-03 2:06 Mounting CF flash card in 2.6.25 vb
2008-06-03 15:41 ` vb
2008-06-03 16:19 ` Alan Cox
2008-06-03 16:48 ` vb
2008-06-03 17:34 ` Michael Tokarev
2008-06-03 17:49 ` vb
2008-06-03 18:13 ` vb
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox