2004-03-07 14:55:09

by Carlo Orecchia

[permalink] [raw]
Subject: KERNEL 2.6.3 and MAXTOR 160 GB

HI

I'm running redhat 9 on an XP 1800 and a ASUS A7A266. I recently buy a new
HD a maxtor Diamond Plus 160 with 8 mega cache. The fact is that the kernel that comes
with REDHAT (2.4.20-8) shows the entire size of the disk (163.7 gb) but
the kernel 2.6.1 or 2.6.3 does not. It only shows 137 gb. I'm getting
crazy trying to understand why this is happening! Please let
me know if theres a patch to fix this. I really found amazing the 2.6
kernel and i don't want to come back to use the 2.4!
What can i do?

p.s. let know if you need more info about my system


Regards

Carlo Orecchia


2004-03-07 15:08:10

by Andries Brouwer

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB

On Sun, Mar 07, 2004 at 03:57:11PM +0100, Carlo Orecchia wrote:

> I'm running redhat 9 on an XP 1800 and a ASUS A7A266. I recently buy a new
> HD a maxtor Diamond Plus 160 with 8 mega cache. The fact is that the kernel that comes
> with REDHAT (2.4.20-8) shows the entire size of the disk (163.7 gb) but
> the kernel 2.6.1 or 2.6.3 does not. It only shows 137 gb. I'm getting
> crazy trying to understand why this is happening! Please let
> me know if theres a patch to fix this. I really found amazing the 2.6
> kernel and i don't want to come back to use the 2.4!
> What can i do?

You can tell us the boot messages that concern your disk.
You can tell us the CONFIG options that concern IDE.
For example, did you set CONFIG_IDEDISK_STROKE ?

2004-03-07 16:24:29

by Stephen D. Williams

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB

Be sure that you are really connected to a newer IDE controller. This is what
determines whether the OS sees 137GB or the full amount.

2.6.3 and really all recent kernels have worked on hard drives up to 250GB
with the correct controllers for both IDE and Firewire bridge boards.

Now about those 2.6.3 lockups that I am completely in the dark about...

sdw
--
[email protected] http://www.hpti.com Per: [email protected] http://sdw.st
Stephen D. Williams 703-724-0118W 703-995-0407Fax 20147-4622 AIM: sdw

On Sun, March 7, 2004 9:57 am, Carlo Orecchia said:
> HI
>
> I'm running redhat 9 on an XP 1800 and a ASUS A7A266. I recently buy a new
> HD a maxtor Diamond Plus 160 with 8 mega cache. The fact is that the kernel
> that comes
> with REDHAT (2.4.20-8) shows the entire size of the disk (163.7 gb) but
> the kernel 2.6.1 or 2.6.3 does not. It only shows 137 gb. I'm getting
> crazy trying to understand why this is happening! Please let
> me know if theres a patch to fix this. I really found amazing the 2.6
> kernel and i don't want to come back to use the 2.4!
> What can i do?
>
> p.s. let know if you need more info about my system
>
>
> Regards
>
> Carlo Orecchia
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>

2004-03-07 16:36:41

by Carlo Orecchia

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB

Here is the boot message that concern my disk

RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize
Uniform Multi-Platform E-IDE driver Revision: 7.00beta-2.4
ide: Assuming 33MHz system bus speed for PIO modes; override with
idebus=xx
ALI15X3: IDE controller at PCI slot 00:04.0
ALI15X3: chipset revision 196
ALI15X3: not 100% native mode: will probe irqs later
ide0: BM-DMA at 0xb400-0xb407, BIOS settings: hda:DMA, hdb:pio
ide1: BM-DMA at 0xb408-0xb40f, BIOS settings: hdc:pio, hdd:pio
hda: Maxtor 6Y160P0, ATA DISK drive
blk: queue c03be900, I/O limit 4095Mb (mask 0xffffffff)
hdc: no response (status = 0xa1), resetting drive
hdc: no response (status = 0xa1)
hdd: no response (status = 0xa1), resetting drive
hdd: no response (status = 0xa1)
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
hda: host protected area => 1
hda: 320173056 sectors (163929 MB) w/7936KiB Cache, CHS=19929/255/63,
UDMA(100)
ide-floppy driver 0.99.newide
Partition check:
hda: hda1 hda2 hda3 hda4 < hda5 hda6 >
ide-floppy driver 0.99.newide
md: md driver 0.90.0 MAX_MD_DEVS=256, MD_SB_DISKS=27
md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.

Here is the kernel config


# ATA/ATAPI/MFM/RLL support
#
CONFIG_IDE=y
CONFIG_BLK_DEV_IDE=y

#
# Please see Documentation/ide.txt for help/info on IDE drives
#
# CONFIG_BLK_DEV_HD_IDE is not set
CONFIG_BLK_DEV_IDEDISK=y
CONFIG_IDEDISK_MULTI_MODE=y
# CONFIG_IDEDISK_STROKE is not set
CONFIG_BLK_DEV_IDECD=y
# CONFIG_BLK_DEV_IDETAPE is not set
CONFIG_BLK_DEV_IDEFLOPPY=y
CONFIG_BLK_DEV_IDESCSI=y
# CONFIG_IDE_TASK_IOCTL is not set
# CONFIG_IDE_TASKFILE_IO is not set

#
# IDE chipset support/bugfixes
#
CONFIG_IDE_GENERIC=y
CONFIG_BLK_DEV_CMD640=y
# CONFIG_BLK_DEV_CMD640_ENHANCED is not set
CONFIG_BLK_DEV_IDEPNP=y
CONFIG_BLK_DEV_IDEPCI=y
CONFIG_IDEPCI_SHARE_IRQ=y
# CONFIG_BLK_DEV_OFFBOARD is not set
CONFIG_BLK_DEV_GENERIC=y
# CONFIG_BLK_DEV_OPTI621 is not set
CONFIG_BLK_DEV_RZ1000=y
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_ADMA=y
CONFIG_BLK_DEV_AEC62XX=y
CONFIG_BLK_DEV_ALI15X3=y
# CONFIG_WDC_ALI15X3 is not set
CONFIG_BLK_DEV_AMD74XX=y
CONFIG_BLK_DEV_CMD64X=y
CONFIG_BLK_DEV_TRIFLEX=y
CONFIG_BLK_DEV_CY82C693=y
# CONFIG_BLK_DEV_CS5520 is not set
CONFIG_BLK_DEV_CS5530=y
CONFIG_BLK_DEV_HPT34X=y
# CONFIG_HPT34X_AUTODMA is not set
CONFIG_BLK_DEV_HPT366=y
CONFIG_BLK_DEV_SC1200=y
CONFIG_BLK_DEV_PIIX=y
# CONFIG_BLK_DEV_NS87415 is not set
CONFIG_BLK_DEV_PDC202XX_OLD=y
# CONFIG_PDC202XX_BURST is not set
# CONFIG_BLK_DEV_PDC202XX_NEW is not set
CONFIG_BLK_DEV_SVWKS=y
CONFIG_BLK_DEV_SIIMAGE=y
CONFIG_BLK_DEV_SIS5513=y
CONFIG_BLK_DEV_SLC90E66=y
CONFIG_BLK_DEV_TRM290=y
CONFIG_BLK_DEV_VIA82CXXX=y
# CONFIG_IDE_CHIPSETS is not set
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_IVB is not set
CONFIG_IDEDMA_AUTO=y
# CONFIG_DMA_NONPCI is not set
# CONFIG_BLK_DEV_HD is not set

Hope is correct


Thanks for replying

Carlo.

On Sun, 7 Mar 2004, Andries Brouwer wrote:

> On Sun, Mar 07, 2004 at 03:57:11PM +0100, Carlo Orecchia wrote:
>
> > I'm running redhat 9 on an XP 1800 and a ASUS A7A266. I recently buy a new
> > HD a maxtor Diamond Plus 160 with 8 mega cache. The fact is that the kernel that comes
> > with REDHAT (2.4.20-8) shows the entire size of the disk (163.7 gb) but
> > the kernel 2.6.1 or 2.6.3 does not. It only shows 137 gb. I'm getting
> > crazy trying to understand why this is happening! Please let
> > me know if theres a patch to fix this. I really found amazing the 2.6
> > kernel and i don't want to come back to use the 2.4!
> > What can i do?
>
> You can tell us the boot messages that concern your disk.
> You can tell us the CONFIG options that concern IDE.
> For example, did you set CONFIG_IDEDISK_STROKE ?
>

2004-03-07 18:00:54

by Marc Schiffbauer

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB

* Andries Brouwer schrieb am 07.03.04 um 16:08 Uhr:
> On Sun, Mar 07, 2004 at 03:57:11PM +0100, Carlo Orecchia wrote:
>
> > I'm running redhat 9 on an XP 1800 and a ASUS A7A266. I recently buy a new
> > HD a maxtor Diamond Plus 160 with 8 mega cache. The fact is that the kernel that comes
> > with REDHAT (2.4.20-8) shows the entire size of the disk (163.7 gb) but
> > the kernel 2.6.1 or 2.6.3 does not. It only shows 137 gb. I'm getting
> > crazy trying to understand why this is happening! Please let
> > me know if theres a patch to fix this. I really found amazing the 2.6
> > kernel and i don't want to come back to use the 2.4!
> > What can i do?
>
> You can tell us the boot messages that concern your disk.
> You can tell us the CONFIG options that concern IDE.
> For example, did you set CONFIG_IDEDISK_STROKE ?
>

The disk works for me (TM).


homer:~# uname -a
Linux homer 2.6.3 #2 Thu Feb 26 19:38:13 CET 2004 i686 GNU/Linux
homer:~# hdparm -i /dev/hde

/dev/hde:

Model=Maxtor 6Y160P0, FwRev=YAR41BW0, SerialNo=Y43V47SE
Config={ Fixed }
RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=57
BuffType=DualPortCache, BuffSize=7936kB, MaxMultSect=16,
MultSect=16
CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=268435455
IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
PIO modes: pio0 pio1 pio2 pio3 pio4
DMA modes: mdma0 mdma1 mdma2
UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5 udma6
AdvancedPM=yes: disabled (255) WriteCache=enabled
Drive conforms to: (null):

* signifies the current active mode

homer:~# fdisk -l /dev/hde

Disk /dev/hde: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes


boot messages (ide specific part):

Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with
idebus=xx
VP_IDE: IDE controller at PCI slot 0000:00:04.1
VP_IDE: chipset revision 16
VP_IDE: not 100% native mode: will probe irqs later
ide: Assuming 33MHz system bus speed for PIO modes; override with
idebus=xx
VP_IDE: VIA vt82c686a (rev 22) IDE UDMA66 controller on
pci0000:00:04.1
ide0: BM-DMA at 0xd800-0xd807, BIOS settings: hda:pio, hdb:pio
ide1: BM-DMA at 0xd808-0xd80f, BIOS settings: hdc:DMA, hdd:pio
hda: HL-DT-ST GCE-8400B, ATAPI CD/DVD-ROM drive
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
hdc: Pioneer DVD-ROM ATAPIModel DVD-105S 011, ATAPI CD/DVD-ROM drive
ide1 at 0x170-0x177,0x376 on irq 15
PDC20265: IDE controller at PCI slot 0000:00:11.0
PCI: Found IRQ 10 for device 0000:00:11.0
PCI: Sharing IRQ 10 with 0000:00:0b.0
PDC20265: chipset revision 2
PDC20265: 100% native mode on irq 10
PDC20265: (U)DMA Burst Bit ENABLED Primary PCI Mode Secondary PCI
Mode.
ide2: BM-DMA at 0x8000-0x8007, BIOS settings: hde:DMA, hdf:pio
ide3: BM-DMA at 0x8008-0x800f, BIOS settings: hdg:pio, hdh:pio
hde: Maxtor 6Y160P0, ATA DISK drive
ide2 at 0x9400-0x9407,0x9002 on irq 10
hde: max request size: 1024KiB
hde: 320173056 sectors (163928 MB) w/7936KiB Cache,
CHS=19929/255/63, UDMA(100)
/dev/ide/host2/bus0/target0/lun0: p1 p2 < p5 p6 p7 p8 p9 p10 >


config:

homer:~# grep _IDE /usr/src/linux-2.6.3/.config
CONFIG_IDE=y
CONFIG_BLK_DEV_IDE=y
# CONFIG_BLK_DEV_HD_IDE is not set
CONFIG_BLK_DEV_IDEDISK=y
CONFIG_IDEDISK_MULTI_MODE=y
# CONFIG_IDEDISK_STROKE is not set
CONFIG_BLK_DEV_IDECD=m
# CONFIG_BLK_DEV_IDETAPE is not set
# CONFIG_BLK_DEV_IDEFLOPPY is not set
CONFIG_BLK_DEV_IDESCSI=m
# CONFIG_IDE_TASK_IOCTL is not set
# CONFIG_IDE_TASKFILE_IO is not set
CONFIG_IDE_GENERIC=y
CONFIG_BLK_DEV_IDEPCI=y
CONFIG_IDEPCI_SHARE_IRQ=y
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_IVB is not set
CONFIG_IDEDMA_AUTO=y
homer:~#


-Marc

--
+-O . . . o . . . O . . . o . . . O . . . ___ . . . O . . . o .-+
| Ein Service von Links2Linux.de: / o\ RPMs for SuSE |
| --> PackMan! <-- naeheres unter | __| and others |
| http://packman.links2linux.de/ . . . O \__\ . . . O . . . O . |

2004-03-07 22:24:37

by Carlo Orecchia

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB



Sorry my stupid mistake .. this is the correct message from boot:
Thanks for any reply!!

ide: Assuming 33MHz system bus speed for PIO modes; override with
idebus=xx
ALI15X3: IDE controller at PCI slot 0000:00:04.0
ACPI: No IRQ known for interrupt pin A of device 0000:00:04.0 - using IRQ
255
ALI15X3: chipset revision 196
ALI15X3: not 100% native mode: will probe irqs later
ide0: BM-DMA at 0xb400-0xb407, BIOS settings: hda:DMA, hdb:pio
ide1: BM-DMA at 0xb408-0xb40f, BIOS settings: hdc:pio, hdd:pio
hda: Maxtor 6Y160P0, ATA DISK drive
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
hdc: no response (status = 0xa1), resetting drive
hdc: no response (status = 0xa1)
hdd: no response (status = 0xa1), resetting drive
hdd: no response (status = 0xa1)
hdc: no response (status = 0xa1), resetting drive
hdc: no response (status = 0xa1)
hdd: no response (status = 0xa1), resetting drive
hdd: no response (status = 0xa1)
hda: max request size: 128KiB
hda: cannot use LBA48 - full capacity 320173056 sectors (163928 MB)
hda: 268435456 sectors (137438 MB) w/7936KiB Cache, CHS=16709/255/63,
UDMA(100)
hda: hda1 hda2 hda3 hda4 < hda5 hda6 >
ide-floppy driver 0.99.newide
Console: switching to colour frame buffer device 100x37
mice: PS/2 mouse device common for all mice
ts: Compaq touchscreen protocol output
input: PC Speaker
serio: i8042 AUX port at 0x60,0x64 irq 12
input: ImPS/2 Logitech Wheel Mouse on isa0060/serio1
serio: i8042 KBD port at 0x60,0x64 irq 1
input: AT Translated Set 2 keyboard on isa0060/serio0
Advanced Linux Sound Architecture Driver Version 1.0.2c (Thu Feb 05
15:41:49 2004 UTC).
ALSA device list:
#0: C-Media PCI CMI8738-MC6 (model 55) at 0xb000, irq 9
NET: Registered protocol family 2
IP: routing cache hash table of 8192 buckets, 64Kbytes
TCP: Hash tables configured (established 262144 bind 65536)
IPv4 over IPv4 tunneling driver
GRE over IPv4 tunneling driver
ip_conntrack version 2.1 (6143 buckets, 49144 max) - 300 bytes per
conntrack
ip_tables: (C) 2000-2002 Netfilter core team
ipt_recent v0.3.1: Stephen Frost <[email protected]>.
http://snowman.net/projects/ipt_recent/
arp_tables: (C) 2002 David S. Miller
NET: Registered protocol family 1
NET: Registered protocol family 17
NET: Registered protocol family 15
ACPI: (supports S0 S1 S4 S5)
kjournald starting. Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 272k freed
drivers/usb/core/usb.c: registered new driver usbfs
drivers/usb/core/usb.c: registered new driver hub
ohci_hcd: 2004 Feb 02 USB 1.1 'Open' Host Controller (OHCI) Driver (PCI)
ohci_hcd: block sizes: ed 64 td 64
ohci_hcd 0000:00:02.0: OHCI Host Controller
ohci_hcd 0000:00:02.0: irq 9, pci mem f1864000
ohci_hcd 0000:00:02.0: new USB bus registered, assigned bus number 1
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 4 ports detected
ohci_hcd 0000:00:06.0: OHCI Host Controller
ohci_hcd 0000:00:06.0: irq 9, pci mem f1866000
ohci_hcd 0000:00:06.0: new USB bus registered, assigned bus number 2
hub 2-0:1.0: USB hub found
hub 2-0:1.0: 2 ports detected
drivers/usb/core/usb.c: registered new driver hid
drivers/usb/input/hid-core.c: v2.0:USB HID core driver
drivers/usb/core/usb.c: registered new driver usbkbd
drivers/usb/input/usbkbd.c: :USB HID Boot Protocol keyboard driver
drivers/usb/core/usb.c: registered new driver usbmouse


Here is the .config of kernel (ATA section)

# ATA/ATAPI/MFM/RLL support
#
CONFIG_IDE=y
CONFIG_BLK_DEV_IDE=y

#
# Please see Documentation/ide.txt for help/info on IDE drives
#
# CONFIG_BLK_DEV_HD_IDE is not set
CONFIG_BLK_DEV_IDEDISK=y
CONFIG_IDEDISK_MULTI_MODE=y
CONFIG_IDEDISK_STROKE=y
CONFIG_BLK_DEV_IDECD=y
# CONFIG_BLK_DEV_IDETAPE is not set
CONFIG_BLK_DEV_IDEFLOPPY=y
CONFIG_BLK_DEV_IDESCSI=y
# CONFIG_IDE_TASK_IOCTL is not set
# CONFIG_IDE_TASKFILE_IO is not set

#
# IDE chipset support/bugfixes
#
CONFIG_IDE_GENERIC=y
CONFIG_BLK_DEV_CMD640=y
# CONFIG_BLK_DEV_CMD640_ENHANCED is not set
CONFIG_BLK_DEV_IDEPNP=y
CONFIG_BLK_DEV_IDEPCI=y
CONFIG_IDEPCI_SHARE_IRQ=y
# CONFIG_BLK_DEV_OFFBOARD is not set
CONFIG_BLK_DEV_GENERIC=y
# CONFIG_BLK_DEV_OPTI621 is not set
CONFIG_BLK_DEV_RZ1000=y
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_ADMA=y
CONFIG_BLK_DEV_AEC62XX=y
CONFIG_BLK_DEV_ALI15X3=y
# CONFIG_WDC_ALI15X3 is not set
CONFIG_BLK_DEV_AMD74XX=y
CONFIG_BLK_DEV_CMD64X=y
CONFIG_BLK_DEV_TRIFLEX=y
CONFIG_BLK_DEV_CY82C693=y
# CONFIG_BLK_DEV_CS5520 is not set
CONFIG_BLK_DEV_CS5530=y
CONFIG_BLK_DEV_HPT34X=y
# CONFIG_HPT34X_AUTODMA is not set
CONFIG_BLK_DEV_HPT366=y
CONFIG_BLK_DEV_SC1200=y
CONFIG_BLK_DEV_PIIX=y
# CONFIG_BLK_DEV_NS87415 is not set
CONFIG_BLK_DEV_PDC202XX_OLD=y
# CONFIG_PDC202XX_BURST is not set
# CONFIG_BLK_DEV_PDC202XX_NEW is not set
CONFIG_BLK_DEV_SVWKS=y
CONFIG_BLK_DEV_SIIMAGE=y
CONFIG_BLK_DEV_SIS5513=y
CONFIG_BLK_DEV_SLC90E66=y
CONFIG_BLK_DEV_TRM290=y
CONFIG_BLK_DEV_VIA82CXXX=y
# CONFIG_IDE_CHIPSETS is not set
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_IVB is not set
CONFIG_IDEDMA_AUTO=y
# CONFIG_DMA_NONPCI is not set
# CONFIG_BLK_DEV_HD is not set

2004-03-07 23:46:09

by David B. Stevens

[permalink] [raw]
Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB

Carlo,

From the driver code:


/* Don't use LBA48 on ALi devices before rev 0xC5 */
hwif->no_lba48 = (m5229_revision <= 0xC4) ? 1 : 0;

0xC5 is revision 197 your system has a revision 196 chipset.

The inabilty to use LBA48 with that chipset version is why Linux is saying:

hda: cannot use LBA48 - full capacity 320173056 sectors (163928 MB)
hda: 268435456 sectors (137438 MB) w/7936KiB Cache, CHS=16709/255/63,

and restricting you to use only 137 GB of that drive.

2.6 knows it is a 160GB drive but the chipset can't handle anything
above 137GB.

Cheers,
Dave

Carlo Orecchia wrote:
>
> Sorry my stupid mistake .. this is the correct message from boot:
> Thanks for any reply!!
>
> ide: Assuming 33MHz system bus speed for PIO modes; override with
> idebus=xx
> ALI15X3: IDE controller at PCI slot 0000:00:04.0
> ACPI: No IRQ known for interrupt pin A of device 0000:00:04.0 - using IRQ
> 255
> ALI15X3: chipset revision 196
> ALI15X3: not 100% native mode: will probe irqs later
> ide0: BM-DMA at 0xb400-0xb407, BIOS settings: hda:DMA, hdb:pio
> ide1: BM-DMA at 0xb408-0xb40f, BIOS settings: hdc:pio, hdd:pio
> hda: Maxtor 6Y160P0, ATA DISK drive
> ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
> hdc: no response (status = 0xa1), resetting drive
> hdc: no response (status = 0xa1)
> hdd: no response (status = 0xa1), resetting drive
> hdd: no response (status = 0xa1)
> hdc: no response (status = 0xa1), resetting drive
> hdc: no response (status = 0xa1)
> hdd: no response (status = 0xa1), resetting drive
> hdd: no response (status = 0xa1)
> hda: max request size: 128KiB
> hda: cannot use LBA48 - full capacity 320173056 sectors (163928 MB)
> hda: 268435456 sectors (137438 MB) w/7936KiB Cache, CHS=16709/255/63,
> UDMA(100)
> hda: hda1 hda2 hda3 hda4 < hda5 hda6 >
> ide-floppy driver 0.99.newide
> Console: switching to colour frame buffer device 100x37
> mice: PS/2 mouse device common for all mice
> ts: Compaq touchscreen protocol output
> input: PC Speaker
> serio: i8042 AUX port at 0x60,0x64 irq 12
> input: ImPS/2 Logitech Wheel Mouse on isa0060/serio1
> serio: i8042 KBD port at 0x60,0x64 irq 1
> input: AT Translated Set 2 keyboard on isa0060/serio0
> Advanced Linux Sound Architecture Driver Version 1.0.2c (Thu Feb 05
> 15:41:49 2004 UTC).
> ALSA device list:
> #0: C-Media PCI CMI8738-MC6 (model 55) at 0xb000, irq 9
> NET: Registered protocol family 2
> IP: routing cache hash table of 8192 buckets, 64Kbytes
> TCP: Hash tables configured (established 262144 bind 65536)
> IPv4 over IPv4 tunneling driver
> GRE over IPv4 tunneling driver
> ip_conntrack version 2.1 (6143 buckets, 49144 max) - 300 bytes per
> conntrack
> ip_tables: (C) 2000-2002 Netfilter core team
> ipt_recent v0.3.1: Stephen Frost <[email protected]>.
> http://snowman.net/projects/ipt_recent/
> arp_tables: (C) 2002 David S. Miller
> NET: Registered protocol family 1
> NET: Registered protocol family 17
> NET: Registered protocol family 15
> ACPI: (supports S0 S1 S4 S5)
> kjournald starting. Commit interval 5 seconds
> EXT3-fs: mounted filesystem with ordered data mode.
> VFS: Mounted root (ext3 filesystem) readonly.
> Freeing unused kernel memory: 272k freed
> drivers/usb/core/usb.c: registered new driver usbfs
> drivers/usb/core/usb.c: registered new driver hub
> ohci_hcd: 2004 Feb 02 USB 1.1 'Open' Host Controller (OHCI) Driver (PCI)
> ohci_hcd: block sizes: ed 64 td 64
> ohci_hcd 0000:00:02.0: OHCI Host Controller
> ohci_hcd 0000:00:02.0: irq 9, pci mem f1864000
> ohci_hcd 0000:00:02.0: new USB bus registered, assigned bus number 1
> hub 1-0:1.0: USB hub found
> hub 1-0:1.0: 4 ports detected
> ohci_hcd 0000:00:06.0: OHCI Host Controller
> ohci_hcd 0000:00:06.0: irq 9, pci mem f1866000
> ohci_hcd 0000:00:06.0: new USB bus registered, assigned bus number 2
> hub 2-0:1.0: USB hub found
> hub 2-0:1.0: 2 ports detected
> drivers/usb/core/usb.c: registered new driver hid
> drivers/usb/input/hid-core.c: v2.0:USB HID core driver
> drivers/usb/core/usb.c: registered new driver usbkbd
> drivers/usb/input/usbkbd.c: :USB HID Boot Protocol keyboard driver
> drivers/usb/core/usb.c: registered new driver usbmouse
>
>
> Here is the .config of kernel (ATA section)
>
> # ATA/ATAPI/MFM/RLL support
> #
> CONFIG_IDE=y
> CONFIG_BLK_DEV_IDE=y
>
> #
> # Please see Documentation/ide.txt for help/info on IDE drives
> #
> # CONFIG_BLK_DEV_HD_IDE is not set
> CONFIG_BLK_DEV_IDEDISK=y
> CONFIG_IDEDISK_MULTI_MODE=y
> CONFIG_IDEDISK_STROKE=y
> CONFIG_BLK_DEV_IDECD=y
> # CONFIG_BLK_DEV_IDETAPE is not set
> CONFIG_BLK_DEV_IDEFLOPPY=y
> CONFIG_BLK_DEV_IDESCSI=y
> # CONFIG_IDE_TASK_IOCTL is not set
> # CONFIG_IDE_TASKFILE_IO is not set
>
> #
> # IDE chipset support/bugfixes
> #
> CONFIG_IDE_GENERIC=y
> CONFIG_BLK_DEV_CMD640=y
> # CONFIG_BLK_DEV_CMD640_ENHANCED is not set
> CONFIG_BLK_DEV_IDEPNP=y
> CONFIG_BLK_DEV_IDEPCI=y
> CONFIG_IDEPCI_SHARE_IRQ=y
> # CONFIG_BLK_DEV_OFFBOARD is not set
> CONFIG_BLK_DEV_GENERIC=y
> # CONFIG_BLK_DEV_OPTI621 is not set
> CONFIG_BLK_DEV_RZ1000=y
> CONFIG_BLK_DEV_IDEDMA_PCI=y
> # CONFIG_BLK_DEV_IDEDMA_FORCED is not set
> CONFIG_IDEDMA_PCI_AUTO=y
> # CONFIG_IDEDMA_ONLYDISK is not set
> CONFIG_BLK_DEV_ADMA=y
> CONFIG_BLK_DEV_AEC62XX=y
> CONFIG_BLK_DEV_ALI15X3=y
> # CONFIG_WDC_ALI15X3 is not set
> CONFIG_BLK_DEV_AMD74XX=y
> CONFIG_BLK_DEV_CMD64X=y
> CONFIG_BLK_DEV_TRIFLEX=y
> CONFIG_BLK_DEV_CY82C693=y
> # CONFIG_BLK_DEV_CS5520 is not set
> CONFIG_BLK_DEV_CS5530=y
> CONFIG_BLK_DEV_HPT34X=y
> # CONFIG_HPT34X_AUTODMA is not set
> CONFIG_BLK_DEV_HPT366=y
> CONFIG_BLK_DEV_SC1200=y
> CONFIG_BLK_DEV_PIIX=y
> # CONFIG_BLK_DEV_NS87415 is not set
> CONFIG_BLK_DEV_PDC202XX_OLD=y
> # CONFIG_PDC202XX_BURST is not set
> # CONFIG_BLK_DEV_PDC202XX_NEW is not set
> CONFIG_BLK_DEV_SVWKS=y
> CONFIG_BLK_DEV_SIIMAGE=y
> CONFIG_BLK_DEV_SIS5513=y
> CONFIG_BLK_DEV_SLC90E66=y
> CONFIG_BLK_DEV_TRM290=y
> CONFIG_BLK_DEV_VIA82CXXX=y
> # CONFIG_IDE_CHIPSETS is not set
> CONFIG_BLK_DEV_IDEDMA=y
> # CONFIG_IDEDMA_IVB is not set
> CONFIG_IDEDMA_AUTO=y
> # CONFIG_DMA_NONPCI is not set
> # CONFIG_BLK_DEV_HD is not set
>
>

Subject: Re: KERNEL 2.6.3 and MAXTOR 160 GB


On Sunday 07 of March 2004 23:26, Carlo Orecchia wrote:
> Sorry my stupid mistake .. this is the correct message from boot:
> Thanks for any reply!!
>
> ide: Assuming 33MHz system bus speed for PIO modes; override with
> idebus=xx
> ALI15X3: IDE controller at PCI slot 0000:00:04.0
> ACPI: No IRQ known for interrupt pin A of device 0000:00:04.0 - using IRQ
> 255
> ALI15X3: chipset revision 196
> ALI15X3: not 100% native mode: will probe irqs later
> ide0: BM-DMA at 0xb400-0xb407, BIOS settings: hda:DMA, hdb:pio
> ide1: BM-DMA at 0xb408-0xb40f, BIOS settings: hdc:pio, hdd:pio
> hda: Maxtor 6Y160P0, ATA DISK drive
> ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
> hdc: no response (status = 0xa1), resetting drive
> hdc: no response (status = 0xa1)
> hdd: no response (status = 0xa1), resetting drive
> hdd: no response (status = 0xa1)
> hdc: no response (status = 0xa1), resetting drive
> hdc: no response (status = 0xa1)
> hdd: no response (status = 0xa1), resetting drive
> hdd: no response (status = 0xa1)
> hda: max request size: 128KiB
> hda: cannot use LBA48 - full capacity 320173056 sectors (163928 MB)
> hda: 268435456 sectors (137438 MB) w/7936KiB Cache, CHS=16709/255/63,
> UDMA(100)

Your IDE controller doesn't support DMA transfer modes when LBA48 is used.
This means that access to the > 137GB part of the disk can only be done
using PIO modes (slow!).

Patch below (against kernel 2.6.4-rc2) should fix access to >137GB part
of the disk in the best possible way - IDE driver will always try to use
DMA and revert to PIO only when necessary. I dunno what patches are
included in RedHat's 2.4.20-8 but kernels < 2.4.23 can silently corrupt
your data because of this issue (and you still won't access whole disk
with >= 2.4.23, although -ac tree contained fix which just turned DMA off).

> # CONFIG_IDE_TASKFILE_IO is not set

Please don't set it to 'y' while using this patch (because it's harder to
fix for CONFIG_IDE_TASKFILE_IO and conflicts with other pending patches).

Regards,
Bartlomiej

linux-2.6.4-rc2-root/drivers/ide/ide-disk.c | 29 +++++++++++++++++-------
linux-2.6.4-rc2-root/drivers/ide/ide-probe.c | 8 ++++--
linux-2.6.4-rc2-root/drivers/ide/pci/alim15x3.c | 4 +--
linux-2.6.4-rc2-root/include/linux/ide.h | 1
4 files changed, 30 insertions(+), 12 deletions(-)

diff -puN drivers/ide/ide-disk.c~ide_no_lba48_dma drivers/ide/ide-disk.c
--- linux-2.6.4-rc2/drivers/ide/ide-disk.c~ide_no_lba48_dma 2004-03-08 00:07:38.518961600 +0100
+++ linux-2.6.4-rc2-root/drivers/ide/ide-disk.c 2004-03-08 00:51:05.705608984 +0100
@@ -470,12 +470,15 @@ ide_startstop_t __ide_do_rw_disk (ide_dr
}

if (rq_data_dir(rq) == READ) {
+ if (!drive->hwif->no_lba48_dma ||
+ rq->sector + rq->nr_sectors < 1ULL << 28) {
#ifdef CONFIG_BLK_DEV_IDE_TCQ
- if (blk_rq_tagged(rq))
- return __ide_dma_queued_read(drive);
+ if (blk_rq_tagged(rq))
+ return __ide_dma_queued_read(drive);
#endif
- if (drive->using_dma && !hwif->ide_dma_read(drive))
- return ide_started;
+ if (drive->using_dma && !hwif->ide_dma_read(drive))
+ return ide_started;
+ }

command = ((drive->mult_count) ?
((lba48) ? WIN_MULTREAD_EXT : WIN_MULTREAD) :
@@ -484,12 +487,16 @@ ide_startstop_t __ide_do_rw_disk (ide_dr
return ide_started;
} else if (rq_data_dir(rq) == WRITE) {
ide_startstop_t startstop;
+
+ if (!drive->hwif->no_lba48_dma ||
+ rq->sector + rq->nr_sectors < 1ULL << 28) {
#ifdef CONFIG_BLK_DEV_IDE_TCQ
- if (blk_rq_tagged(rq))
- return __ide_dma_queued_write(drive);
+ if (blk_rq_tagged(rq))
+ return __ide_dma_queued_write(drive);
#endif
- if (drive->using_dma && !(HWIF(drive)->ide_dma_write(drive)))
- return ide_started;
+ if (drive->using_dma && !hwif->ide_dma_write(drive))
+ return ide_started;
+ }

command = ((drive->mult_count) ?
((lba48) ? WIN_MULTWRITE_EXT : WIN_MULTWRITE) :
@@ -1601,6 +1608,12 @@ static void idedisk_setup (ide_drive_t *
drive->capacity64 = 1ULL << 28;
}

+ if (drive->hwif->no_lba48_dma && drive->capacity64 > 1ULL << 28) {
+ printk(KERN_INFO "%s: cannot use LBA48 DMA - PIO mode will be"
+ "used for accessing sectors > %u\n",
+ drive->name, 1 << 28);
+ }
+
/*
* if possible, give fdisk access to more of the drive,
* by correcting bios_cyls:
diff -puN drivers/ide/ide-probe.c~ide_no_lba48_dma drivers/ide/ide-probe.c
--- linux-2.6.4-rc2/drivers/ide/ide-probe.c~ide_no_lba48_dma 2004-03-08 00:07:38.522960992 +0100
+++ linux-2.6.4-rc2-root/drivers/ide/ide-probe.c 2004-03-08 00:07:38.531959624 +0100
@@ -922,8 +922,12 @@ static int ide_init_queue(ide_drive_t *d
q->queuedata = HWGROUP(drive);
blk_queue_segment_boundary(q, 0xffff);

- if (!hwif->rqsize)
- hwif->rqsize = hwif->no_lba48 ? 256 : 65536;
+ if (!hwif->rqsize) {
+ if (hwif->no_lba48 || hwif->no_lba48_dma)
+ hwif->rqsize = 256;
+ else
+ hwif->rqsize = 65536;
+ }
if (hwif->rqsize < max_sectors)
max_sectors = hwif->rqsize;
blk_queue_max_sectors(q, max_sectors);
diff -puN drivers/ide/pci/alim15x3.c~ide_no_lba48_dma drivers/ide/pci/alim15x3.c
--- linux-2.6.4-rc2/drivers/ide/pci/alim15x3.c~ide_no_lba48_dma 2004-03-08 00:07:38.504963728 +0100
+++ linux-2.6.4-rc2-root/drivers/ide/pci/alim15x3.c 2004-03-08 00:07:38.526960384 +0100
@@ -752,8 +752,8 @@ static void __init init_hwif_common_ali1
hwif->tuneproc = &ali15x3_tune_drive;
hwif->speedproc = &ali15x3_tune_chipset;

- /* Don't use LBA48 on ALi devices before rev 0xC5 */
- hwif->no_lba48 = (m5229_revision <= 0xC4) ? 1 : 0;
+ /* don't use LBA48 DMA on ALi devices before rev 0xC5 */
+ hwif->no_lba48_dma = (m5229_revision <= 0xC4) ? 1 : 0;

if (!hwif->dma_base) {
hwif->drives[0].autotune = 1;
diff -puN include/linux/ide.h~ide_no_lba48_dma include/linux/ide.h
--- linux-2.6.4-rc2/include/linux/ide.h~ide_no_lba48_dma 2004-03-08 00:07:38.515962056 +0100
+++ linux-2.6.4-rc2-root/include/linux/ide.h 2004-03-08 00:07:38.527960232 +0100
@@ -980,6 +980,7 @@ typedef struct hwif_s {
unsigned autodma : 1; /* auto-attempt using DMA at boot */
unsigned udma_four : 1; /* 1=ATA-66 capable, 0=default */
unsigned no_lba48 : 1; /* 1 = cannot do LBA48 */
+ unsigned no_lba48_dma : 1; /* 1 = cannot do LBA48 DMA */
unsigned no_dsc : 1; /* 0 default, 1 dsc_overlap disabled */
unsigned auto_poll : 1; /* supports nop auto-poll */


_