All of lore.kernel.org
 help / color / mirror / Atom feed
* e-SATA ExpressCard - OOPS plus incrementing "ataX" on Linux-2.6.xx
@ 2010-06-14 15:16 Jeff Chua
  2010-06-14 16:20 ` Greg KH
  0 siblings, 1 reply; 10+ messages in thread
From: Jeff Chua @ 2010-06-14 15:16 UTC (permalink / raw)
  To: kristen.c.accardi, Greg Kroah-Hartman, Dely Sy, Linus Torvalds,
	lkml, Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

Hi,

I just buy an e-SATA ExpressCard and trying on my notebook. It's able
to see the external SATA harddisk. On initial boot, I'm seeing the
following OOPS.


2010-06-14T16:43:21.077256+08:00 boston kernel: scsi 6:0:0:0:
Direct-Access     ATA      SAMSUNG MCCOE64G PS10 PQ: 0 ANSI: 5
2010-06-14T16:43:21.077258+08:00 boston kernel: sd 6:0:0:0: [sdb]
125045424 512-byte logical blocks: (64.0 GB/59.6 GiB)
2010-06-14T16:43:21.077260+08:00 boston kernel: sd 6:0:0:0: Attached
scsi generic sg1 type 0
2010-06-14T16:43:21.077261+08:00 boston kernel: sd 6:0:0:0: [sdb]
Write Protect is off
2010-06-14T16:43:21.077264+08:00 boston kernel: sd 6:0:0:0: [sdb] Mode
Sense: 00 3a 00 00
2010-06-14T16:43:21.077266+08:00 boston kernel: sd 6:0:0:0: [sdb]
Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
2010-06-14T16:43:21.077267+08:00 boston kernel: sdb: sdb1
2010-06-14T16:43:21.077268+08:00 boston kernel: sd 6:0:0:0: [sdb]
Attached SCSI disk
2010-06-14T16:43:21.077270+08:00 boston kernel: ------------[ cut here
]------------
2010-06-14T16:43:21.077272+08:00 boston kernel: WARNING: at
fs/sysfs/dir.c:451 sysfs_add_one+0x82/0x95()
2010-06-14T16:43:21.077273+08:00 boston kernel: Hardware name: 5413FGA
2010-06-14T16:43:21.077276+08:00 boston kernel: sysfs: cannot create
duplicate filename
'/devices/pci0000:00/0000:00:1c.3/0000:05:00.0/slot'
2010-06-14T16:43:21.077277+08:00 boston kernel: Modules linked in:
2010-06-14T16:43:21.077279+08:00 boston kernel: Pid: 1, comm: swapper
Not tainted 2.6.35-rc2 #69
2010-06-14T16:43:21.077280+08:00 boston kernel: Call Trace:
2010-06-14T16:43:21.077282+08:00 boston kernel: [<ffffffff8103127c>] ?
warn_slowpath_common+0x78/0x8c
2010-06-14T16:43:21.077284+08:00 boston kernel: [<ffffffff8103132f>] ?
warn_slowpath_fmt+0x45/0x4a
2010-06-14T16:43:21.077286+08:00 boston kernel: [<ffffffff810dcf35>] ?
sysfs_add_one+0x82/0x95
2010-06-14T16:43:21.077288+08:00 boston kernel: [<ffffffff810ddc58>] ?
sysfs_do_create_link+0xdd/0x151
2010-06-14T16:43:21.077291+08:00 boston kernel: [<ffffffff810dc869>] ?
sysfs_add_file_mode+0x56/0x7d
2010-06-14T16:43:21.077293+08:00 boston kernel: [<ffffffff811c82c7>] ?
pci_create_sysfs_dev_files+0x2e4/0x3f6
2010-06-14T16:43:21.077295+08:00 boston kernel: [<ffffffff8173af12>] ?
pci_sysfs_init+0x1b/0x4c
2010-06-14T16:43:21.077296+08:00 boston kernel: [<ffffffff8173aef7>] ?
pci_sysfs_init+0x0/0x4c
2010-06-14T16:43:21.077298+08:00 boston kernel: [<ffffffff810001e0>] ?
do_one_initcall+0x4f/0x149
2010-06-14T16:43:21.077300+08:00 boston kernel: [<ffffffff8171f696>] ?
kernel_init+0x14b/0x1d1
2010-06-14T16:43:21.077301+08:00 boston kernel: [<ffffffff81002ca4>] ?
kernel_thread_helper+0x4/0x10
2010-06-14T16:43:21.077303+08:00 boston kernel: [<ffffffff8171f54b>] ?
kernel_init+0x0/0x1d1
2010-06-14T16:43:21.077306+08:00 boston kernel: [<ffffffff81002ca0>] ?
kernel_thread_helper+0x0/0x10
2010-06-14T16:43:21.077307+08:00 boston kernel: ---[ end trace
962a14d7e07fcb71 ]---


A second problem relating to the ExpressCard is ejecting and inserting
the card. Every time I do so, I'm seeing the new card occupying a new
"ata" interface. See logs below ...


[Message from inserting the card ...]

2010-06-14T23:07:59.383541+08:00 boston kernel: pci 0000:05:00.0: no
hotplug settings from platform
2010-06-14T23:07:59.383541+08:00 boston kernel: pci 0000:05:00.0: no
hotplug settings from platform
2010-06-14T23:07:59.383542+08:00 boston kernel: ahci 0000:05:00.0:
enabling device (0000 -> 0003)
2010-06-14T23:07:59.383542+08:00 boston kernel: ahci 0000:05:00.0:
enabling device (0000 -> 0003)
2010-06-14T23:07:59.383544+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A -> GSI 19 (level, low) -> IRQ 19
2010-06-14T23:07:59.383544+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A -> GSI 19 (level, low) -> IRQ 19
2010-06-14T23:07:59.403405+08:00 boston kernel: ahci 0000:05:00.0:
AHCI 0001.0000 32 slots 1 ports 3 Gbps 0x1 impl SATA mode
2010-06-14T23:07:59.403436+08:00 boston kernel: ahci 0000:05:00.0:
flags: 64bit ncq pm led clo pmp pio slum part
2010-06-14T23:07:59.403442+08:00 boston kernel: ahci 0000:05:00.0:
setting latency timer to 64
2010-06-14T23:07:59.403447+08:00 boston kernel: scsi22 : ahci
2010-06-14T23:07:59.403453+08:00 boston kernel: ata20: SATA max
UDMA/133 abar m8192@0xf0000000 port 0xf0000100 irq 19
2010-06-14T23:07:59.753447+08:00 boston kernel: ata20: SATA link down
(SStatus 0 SControl 300)

[Message from ejecting the card ...]
2010-06-14T23:09:53.713399+08:00 boston kernel: ata20: failed to stop
engine (-5)
2010-06-14T23:09:53.713445+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A disabled

[Message from inserting the card ...]
2010-06-14T23:10:23.553540+08:00 boston kernel: ahci 0000:05:00.0:
enabling device (0000 -> 0003)
2010-06-14T23:10:23.553542+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A -> GSI 19 (level, low) -> IRQ 19
2010-06-14T23:10:23.583430+08:00 boston kernel: ahci 0000:05:00.0:
AHCI 0001.0000 32 slots 1 ports 3 Gbps 0x1 impl SATA mode
2010-06-14T23:10:23.583461+08:00 boston kernel: ahci 0000:05:00.0:
flags: 64bit ncq pm led clo pmp pio slum part
2010-06-14T23:10:23.583465+08:00 boston kernel: ahci 0000:05:00.0:
setting latency timer to 64
2010-06-14T23:10:23.583468+08:00 boston kernel: scsi23 : ahci
2010-06-14T23:10:23.583474+08:00 boston kernel: ata21: SATA max
UDMA/133 abar m8192@0xf0000000 port 0xf0000100 irq 19
2010-06-14T23:10:23.583465+08:00 boston kernel: ahci 0000:05:00.0:
setting latency timer to 64
2010-06-14T23:10:23.583468+08:00 boston kernel: scsi23 : ahci
2010-06-14T23:10:23.583474+08:00 boston kernel: ata21: SATA max
UDMA/133 abar m8192@0xf0000000 port 0xf0000100 irq 19
2010-06-14T23:10:23.913441+08:00 boston kernel: ata21: SATA link down
(SStatus 0 SControl 300)

[Message from ejecting the card ...]
2010-06-14T23:10:44.413404+08:00 boston kernel: ata21: failed to stop
engine (-5)
2010-06-14T23:10:44.413434+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A disabled


It looks like it failed to stop the sata interface. Or perhaps I be
asking ... is there a utility to stop the interface before pulling off
the card?

And often, inserting the card does not make the kernel detect the
event that the card has been inserted. I've to try a few times before
seeing any message. I've disabled rsyslog so that it shows repeated
logs.

I'm testing it on Linux-2.6.35-rc2, but I think it's happening on
older versions as well. I'm using CONFIG_HOTPLUG_PCI_ACPI so that it
can detect the hotplug events on my X201s Lenovo notebook.


Thanks,
Jeff

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on Linux-2.6.xx
  2010-06-14 15:16 e-SATA ExpressCard - OOPS plus incrementing "ataX" on Linux-2.6.xx Jeff Chua
@ 2010-06-14 16:20 ` Greg KH
  2010-06-14 18:44   ` Jeff Chua
  0 siblings, 1 reply; 10+ messages in thread
From: Greg KH @ 2010-06-14 16:20 UTC (permalink / raw)
  To: Jeff Chua
  Cc: kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:
> Hi,
> 
> I just buy an e-SATA ExpressCard and trying on my notebook. It's able
> to see the external SATA harddisk. On initial boot, I'm seeing the
> following OOPS.
> 
> 
> 2010-06-14T16:43:21.077256+08:00 boston kernel: scsi 6:0:0:0:
> Direct-Access     ATA      SAMSUNG MCCOE64G PS10 PQ: 0 ANSI: 5
> 2010-06-14T16:43:21.077258+08:00 boston kernel: sd 6:0:0:0: [sdb]
> 125045424 512-byte logical blocks: (64.0 GB/59.6 GiB)
> 2010-06-14T16:43:21.077260+08:00 boston kernel: sd 6:0:0:0: Attached
> scsi generic sg1 type 0
> 2010-06-14T16:43:21.077261+08:00 boston kernel: sd 6:0:0:0: [sdb]
> Write Protect is off
> 2010-06-14T16:43:21.077264+08:00 boston kernel: sd 6:0:0:0: [sdb] Mode
> Sense: 00 3a 00 00
> 2010-06-14T16:43:21.077266+08:00 boston kernel: sd 6:0:0:0: [sdb]
> Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
> 2010-06-14T16:43:21.077267+08:00 boston kernel: sdb: sdb1
> 2010-06-14T16:43:21.077268+08:00 boston kernel: sd 6:0:0:0: [sdb]
> Attached SCSI disk
> 2010-06-14T16:43:21.077270+08:00 boston kernel: ------------[ cut here
> ]------------
> 2010-06-14T16:43:21.077272+08:00 boston kernel: WARNING: at
> fs/sysfs/dir.c:451 sysfs_add_one+0x82/0x95()
> 2010-06-14T16:43:21.077273+08:00 boston kernel: Hardware name: 5413FGA
> 2010-06-14T16:43:21.077276+08:00 boston kernel: sysfs: cannot create
> duplicate filename
> '/devices/pci0000:00/0000:00:1c.3/0000:05:00.0/slot'

This is a warning that you can ignore, it's been fixed in the latest
tree (2.6.35-rc3).

try that and see.

thanks,

greg k-h

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-14 16:20 ` Greg KH
@ 2010-06-14 18:44   ` Jeff Chua
  2010-06-14 19:35     ` Greg KH
                       ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jeff Chua @ 2010-06-14 18:44 UTC (permalink / raw)
  To: Greg KH
  Cc: kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On Tue, Jun 15, 2010 at 12:20 AM, Greg KH <greg@kroah.com> wrote:
> On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:


> This is a warning that you can ignore, it's been fixed in the latest
> tree (2.6.35-rc3).
>
> try that and see.

Greg,

Ok, just tried rc3 and it's fixed the 1st OOPS.

But I'm still seeing the "ataX" incrementing from ata7 to ata8, ata9
... after taking out and putting back the card. It seems the interface
is still not shutting down properly. ... Any command to shutdown it
down gracefully?

ata9.00: disabled
2010-06-15T02:32:04.531177+08:00 boston kernel: ata9.00: disabled
sd 8:0:0:0: [sdb] Synchronizing SCSI cache
sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
sd 8:0:0:0: [sdb] Stopping disk
sd 8:0:0:0: [sdb] START_STOP FAILED
sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
2010-06-15T02:32:04.568687+08:00 boston kernel: sd 8:0:0:0: [sdb]
Synchronizing SCSI cache
2010-06-15T02:32:04.568715+08:00 boston kernel: sd 8:0:0:0: [sdb]
Result: hostbyte=0x04 driverbyte=0x00
2010-06-15T02:32:04.568719+08:00 boston kernel: sd 8:0:0:0: [sdb] Stopping disk
2010-06-15T02:32:04.568731+08:00 boston kernel: sd 8:0:0:0: [sdb]
START_STOP FAILED
2010-06-15T02:32:04.568735+08:00 boston kernel: sd 8:0:0:0: [sdb]
Result: hostbyte=0x04 driverbyte=0x00
ata9: failed to stop engine (-5)
ahci 0000:05:00.0: PCI INT A disabled
2010-06-15T02:32:05.068765+08:00 boston kernel: ata9: failed to stop engine (-5)
2010-06-15T02:32:05.068797+08:00 boston kernel: ahci 0000:05:00.0: PCI
INT A disabled



Thanks,
Jeff

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on Linux-2.6.xx
  2010-06-14 18:44   ` Jeff Chua
@ 2010-06-14 19:35     ` Greg KH
  2010-06-14 20:17       ` Jeff Chua
  2010-06-14 23:49     ` Robert Hancock
  2010-06-15  1:26     ` Jeff Garzik
  2 siblings, 1 reply; 10+ messages in thread
From: Greg KH @ 2010-06-14 19:35 UTC (permalink / raw)
  To: Jeff Chua
  Cc: kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On Tue, Jun 15, 2010 at 02:44:36AM +0800, Jeff Chua wrote:
> On Tue, Jun 15, 2010 at 12:20 AM, Greg KH <greg@kroah.com> wrote:
> > On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:
> 
> 
> > This is a warning that you can ignore, it's been fixed in the latest
> > tree (2.6.35-rc3).
> >
> > try that and see.
> 
> Greg,
> 
> Ok, just tried rc3 and it's fixed the 1st OOPS.

Note, it was not an oops, just a warning, and would not cause any
problems.

> But I'm still seeing the "ataX" incrementing from ata7 to ata8, ata9
> ... after taking out and putting back the card. It seems the interface
> is still not shutting down properly. ... Any command to shutdown it
> down gracefully?

I don't know, maybe the libata developers can help you out here.

good luck,

greg k-h

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-14 19:35     ` Greg KH
@ 2010-06-14 20:17       ` Jeff Chua
  0 siblings, 0 replies; 10+ messages in thread
From: Jeff Chua @ 2010-06-14 20:17 UTC (permalink / raw)
  To: Greg KH
  Cc: kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On Tue, Jun 15, 2010 at 3:35 AM, Greg KH <greg@kroah.com> wrote:
> On Tue, Jun 15, 2010 at 02:44:36AM +0800, Jeff Chua wrote:
>> On Tue, Jun 15, 2010 at 12:20 AM, Greg KH <greg@kroah.com> wrote:
>> > On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:
>>
>>
>> > This is a warning that you can ignore, it's been fixed in the latest
>> > tree (2.6.35-rc3).
>> >
>> > try that and see.
>>
>> Greg,
>>
>> Ok, just tried rc3 and it's fixed the 1st OOPS.
>
> Note, it was not an oops, just a warning, and would not cause any
> problems.

Ok, understood.


>> But I'm still seeing the "ataX" incrementing from ata7 to ata8, ata9
>> ... after taking out and putting back the card. It seems the interface
>> is still not shutting down properly. ... Any command to shutdown it
>> down gracefully?
> I don't know, maybe the libata developers can help you out here.
> good luck,

Cool.  Hopefully someone has the solution.

Thanks!

Jeff

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-14 18:44   ` Jeff Chua
  2010-06-14 19:35     ` Greg KH
@ 2010-06-14 23:49     ` Robert Hancock
  2010-06-15 12:08       ` Jeff Chua
  2010-06-15  1:26     ` Jeff Garzik
  2 siblings, 1 reply; 10+ messages in thread
From: Robert Hancock @ 2010-06-14 23:49 UTC (permalink / raw)
  To: Jeff Chua
  Cc: Greg KH, kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On 06/14/2010 12:44 PM, Jeff Chua wrote:
> On Tue, Jun 15, 2010 at 12:20 AM, Greg KH<greg@kroah.com>  wrote:
>> On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:
>
>
>> This is a warning that you can ignore, it's been fixed in the latest
>> tree (2.6.35-rc3).
>>
>> try that and see.
>
> Greg,
>
> Ok, just tried rc3 and it's fixed the 1st OOPS.
>
> But I'm still seeing the "ataX" incrementing from ata7 to ata8, ata9
> ... after taking out and putting back the card. It seems the interface
> is still not shutting down properly. ... Any command to shutdown it
> down gracefully?

The ataX number incrementing is normal (it always increments when an ATA 
host is initialized, it doesn't appear the numbers get reused). The 
other messages are the expected result when you surprise-remove the 
card. I think there should be a way to trigger the hotplug code to 
disable the device before you eject it, but I'm not sure what that is 
supposed to be - maybe echo 1 to /sys/device/pci_somethingorother/remove ?

>
> ata9.00: disabled
> 2010-06-15T02:32:04.531177+08:00 boston kernel: ata9.00: disabled
> sd 8:0:0:0: [sdb] Synchronizing SCSI cache
> sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> sd 8:0:0:0: [sdb] Stopping disk
> sd 8:0:0:0: [sdb] START_STOP FAILED
> sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> 2010-06-15T02:32:04.568687+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Synchronizing SCSI cache
> 2010-06-15T02:32:04.568715+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Result: hostbyte=0x04 driverbyte=0x00
> 2010-06-15T02:32:04.568719+08:00 boston kernel: sd 8:0:0:0: [sdb] Stopping disk
> 2010-06-15T02:32:04.568731+08:00 boston kernel: sd 8:0:0:0: [sdb]
> START_STOP FAILED
> 2010-06-15T02:32:04.568735+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Result: hostbyte=0x04 driverbyte=0x00
> ata9: failed to stop engine (-5)
> ahci 0000:05:00.0: PCI INT A disabled
> 2010-06-15T02:32:05.068765+08:00 boston kernel: ata9: failed to stop engine (-5)
> 2010-06-15T02:32:05.068797+08:00 boston kernel: ahci 0000:05:00.0: PCI
> INT A disabled
>
>
>
> Thanks,
> Jeff


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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-14 18:44   ` Jeff Chua
  2010-06-14 19:35     ` Greg KH
  2010-06-14 23:49     ` Robert Hancock
@ 2010-06-15  1:26     ` Jeff Garzik
  2 siblings, 0 replies; 10+ messages in thread
From: Jeff Garzik @ 2010-06-15  1:26 UTC (permalink / raw)
  To: Jeff Chua
  Cc: Greg KH, kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Takayoshi Kochi, Matthew Wilcox

On 06/14/2010 02:44 PM, Jeff Chua wrote:
> On Tue, Jun 15, 2010 at 12:20 AM, Greg KH<greg@kroah.com>  wrote:
>> On Mon, Jun 14, 2010 at 11:16:29PM +0800, Jeff Chua wrote:
>
>
>> This is a warning that you can ignore, it's been fixed in the latest
>> tree (2.6.35-rc3).
>>
>> try that and see.
>
> Greg,
>
> Ok, just tried rc3 and it's fixed the 1st OOPS.
>
> But I'm still seeing the "ataX" incrementing from ata7 to ata8, ata9
> ... after taking out and putting back the card. It seems the interface
> is still not shutting down properly. ... Any command to shutdown it
> down gracefully?

The incrementing of ataX is unrelated to anything else...  Each "new" 
ata interface gets a new id.


> ata9.00: disabled
> 2010-06-15T02:32:04.531177+08:00 boston kernel: ata9.00: disabled
> sd 8:0:0:0: [sdb] Synchronizing SCSI cache
> sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> sd 8:0:0:0: [sdb] Stopping disk
> sd 8:0:0:0: [sdb] START_STOP FAILED
> sd 8:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> 2010-06-15T02:32:04.568687+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Synchronizing SCSI cache
> 2010-06-15T02:32:04.568715+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Result: hostbyte=0x04 driverbyte=0x00
> 2010-06-15T02:32:04.568719+08:00 boston kernel: sd 8:0:0:0: [sdb] Stopping disk
> 2010-06-15T02:32:04.568731+08:00 boston kernel: sd 8:0:0:0: [sdb]
> START_STOP FAILED
> 2010-06-15T02:32:04.568735+08:00 boston kernel: sd 8:0:0:0: [sdb]
> Result: hostbyte=0x04 driverbyte=0x00
> ata9: failed to stop engine (-5)
> ahci 0000:05:00.0: PCI INT A disabled
> 2010-06-15T02:32:05.068765+08:00 boston kernel: ata9: failed to stop engine (-5)

"failed to stop engine" is where the driver is attempting to talk to the 
card, and gracefully shut things down.  If the card does not exist (ie. 
has been removed/ejected), then this is normal behavior.

	Jeff




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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-14 23:49     ` Robert Hancock
@ 2010-06-15 12:08       ` Jeff Chua
  2010-06-15 14:52         ` Robert Hancock
  0 siblings, 1 reply; 10+ messages in thread
From: Jeff Chua @ 2010-06-15 12:08 UTC (permalink / raw)
  To: Robert Hancock, Jeff Garzik
  Cc: Greg KH, kristen.c.accardi, Dely Sy, Linus Torvalds, lkml,
	Rafael J. Wysocki, Matthew Wilcox

On Tue, Jun 15, 2010 at 7:49 AM, Robert Hancock <hancockrwd@gmail.com> wrote:

> The ataX number incrementing is normal (it always increments when an ATA
> host is initialized, it doesn't appear the numbers get reused). The other
> messages are the expected result when you surprise-remove the card. I think
> there should be a way to trigger the hotplug code to disable the device
> before you eject it, but I'm not sure what that is supposed to be - maybe
> echo 1 to /sys/device/pci_somethingorother/remove ?

Robert,

Thanks for the pointer. I found this "remove" is in
/sys/bus/pci/devices/0000:05:00.0/remove

# echo 1 >/sys/bus/pci/devices/0000:05:00.0/remove

ata14.00: disabled
sd 17:0:0:0: [sdb] Synchronizing SCSI cache
sd 17:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
sd 17:0:0:0: [sdb] Stopping disk
sd 17:0:0:0: [sdb] START_STOP FAILED
sd 17:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
ahci 0000:05:00.0: PCI INT A disabled


It's getter better. Next is to really shutdown the "sdb" hard disk. Is
that possible? Would be nice to make the "sd 17:0:0:0: [sdb]
START_STOP FAILED" go away gracefully. Any command to do that?


On Tue, Jun 15, 2010 at 9:26 AM, Jeff Garzik <jeff@garzik.org> wrote:

> The incrementing of ataX is unrelated to anything else...  Each "new" ata interface gets a new id.

Jeff,

With the "remove" command working, it'll be nice to make "ahci"
_reuse_ the interface now that it's removed cleanly. I'm just afaid
that each time the card is removed and reinserted, the ataXX interface
kept incrementing and will eventually does harm to the kernel?


> "failed to stop engine" is where the driver is attempting to talk to the card, and gracefully shut things down.  > If the card does not exist (ie. has been removed/ejected), then this is normal behavior.

Ok, that's fixed with "echo 1 >/sys/bus/pci/devices/0000:05:00.0/remove".



Thanks,
Jeff

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-15 12:08       ` Jeff Chua
@ 2010-06-15 14:52         ` Robert Hancock
  2010-06-15 16:02           ` Jeff Chua
  0 siblings, 1 reply; 10+ messages in thread
From: Robert Hancock @ 2010-06-15 14:52 UTC (permalink / raw)
  To: Jeff Chua
  Cc: Jeff Garzik, Greg KH, kristen.c.accardi, Dely Sy, Linus Torvalds,
	lkml, Rafael J. Wysocki, Matthew Wilcox

On Tue, Jun 15, 2010 at 6:08 AM, Jeff Chua <jeff.chua.linux@gmail.com> wrote:
> On Tue, Jun 15, 2010 at 7:49 AM, Robert Hancock <hancockrwd@gmail.com> wrote:
>
>> The ataX number incrementing is normal (it always increments when an ATA
>> host is initialized, it doesn't appear the numbers get reused). The other
>> messages are the expected result when you surprise-remove the card. I think
>> there should be a way to trigger the hotplug code to disable the device
>> before you eject it, but I'm not sure what that is supposed to be - maybe
>> echo 1 to /sys/device/pci_somethingorother/remove ?
>
> Robert,
>
> Thanks for the pointer. I found this "remove" is in
> /sys/bus/pci/devices/0000:05:00.0/remove
>
> # echo 1 >/sys/bus/pci/devices/0000:05:00.0/remove
>
> ata14.00: disabled
> sd 17:0:0:0: [sdb] Synchronizing SCSI cache
> sd 17:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> sd 17:0:0:0: [sdb] Stopping disk
> sd 17:0:0:0: [sdb] START_STOP FAILED
> sd 17:0:0:0: [sdb] Result: hostbyte=0x04 driverbyte=0x00
> ahci 0000:05:00.0: PCI INT A disabled
>
>
> It's getter better. Next is to really shutdown the "sdb" hard disk. Is
> that possible? Would be nice to make the "sd 17:0:0:0: [sdb]
> START_STOP FAILED" go away gracefully. Any command to do that?

Try echoing 1 to the file for the SCSI disk's "delete" file, something
like: /sys/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/delete

>
>
> On Tue, Jun 15, 2010 at 9:26 AM, Jeff Garzik <jeff@garzik.org> wrote:
>
>> The incrementing of ataX is unrelated to anything else...  Each "new" ata interface gets a new id.
>
> Jeff,
>
> With the "remove" command working, it'll be nice to make "ahci"
> _reuse_ the interface now that it's removed cleanly. I'm just afaid
> that each time the card is removed and reinserted, the ataXX interface
> kept incrementing and will eventually does harm to the kernel?

I don't think so, it's just a number used to associate debug output
for the device. I suppose if you did it 2 billion times it might wrap
negative but even that would just be cosmetic..

>
>
>> "failed to stop engine" is where the driver is attempting to talk to the card, and gracefully shut things down.  > If the card does not exist (ie. has been removed/ejected), then this is normal behavior.
>
> Ok, that's fixed with "echo 1 >/sys/bus/pci/devices/0000:05:00.0/remove".
>
>
>
> Thanks,
> Jeff
>

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

* Re: e-SATA ExpressCard - OOPS plus incrementing "ataX" on  Linux-2.6.xx
  2010-06-15 14:52         ` Robert Hancock
@ 2010-06-15 16:02           ` Jeff Chua
  0 siblings, 0 replies; 10+ messages in thread
From: Jeff Chua @ 2010-06-15 16:02 UTC (permalink / raw)
  To: Robert Hancock
  Cc: Jeff Garzik, Greg KH, kristen.c.accardi, Dely Sy, Linus Torvalds,
	lkml, Rafael J. Wysocki, Matthew Wilcox

On Tue, Jun 15, 2010 at 10:52 PM, Robert Hancock <hancockrwd@gmail.com> wrote:

> Try echoing 1 to the file for the SCSI disk's "delete" file, something
> like: /sys/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/delete

Very nice. That works!

sd 20:0:0:0: [sdb] Synchronizing SCSI cache
sd 20:0:0:0: [sdb] Stopping disk
ata17.00: disabled

/sys has so much cool things there, but I just didn't know what they were.

Thank you so much!

Jeff.

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

end of thread, other threads:[~2010-06-15 16:02 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-14 15:16 e-SATA ExpressCard - OOPS plus incrementing "ataX" on Linux-2.6.xx Jeff Chua
2010-06-14 16:20 ` Greg KH
2010-06-14 18:44   ` Jeff Chua
2010-06-14 19:35     ` Greg KH
2010-06-14 20:17       ` Jeff Chua
2010-06-14 23:49     ` Robert Hancock
2010-06-15 12:08       ` Jeff Chua
2010-06-15 14:52         ` Robert Hancock
2010-06-15 16:02           ` Jeff Chua
2010-06-15  1:26     ` Jeff Garzik

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.