linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: 2.4.x kernels, big ide disks and old bios
@ 2001-12-25 16:38 Andries.Brouwer
  2001-12-25 22:52 ` Eric Lammerts
  2001-12-26 10:39 ` Santiago Garcia Mantinan
  0 siblings, 2 replies; 19+ messages in thread
From: Andries.Brouwer @ 2001-12-25 16:38 UTC (permalink / raw)
  To: jlladono; +Cc: linux-kernel

Josep Lladonosa i Capell:

> Linux adopts the 'false' geometry (65530/16/63) ) to bypass the bios
> boot.

You can see that this is the wrong way around.
When you start your computer, first the BIOS boots, then Linux.
But maybe you mean to say that you set a jumper on the disk
so as to bypass the BIOS boot problem, and that as a result
also Linux sees a smaller disk?

> hdc: IC35L060AVER07-0, ATA DISK drive
> hdc: 66055247 sectors (33820 MB) w/1916KiB Cache, CHS=119150/16/63,

Funny. Where did this CHS come from? Did you give boot parameters?

> setmax.c does its job for my ide ibm - 60Gb, but kernel
> leaves bios parameters - 32Gb

Can you be more explicit? What precisely do you do?
Call setmax in a boot script? And afterwards you can access
the entire disk, but some proc files still mention the old
geometry? Or are there any real problems?
What precisely do you mean by "kernel leaves bios parameters"?


Santiago Garcia Mantinan:

: What I'm using is change the geometry after the boot and before any
: partition besides root is mounted, I do this at the beginning of
: checkroot.sh by calling "/sbin/setmax -d 0 /dev/hda"
: This works ok for me, of course you can have other solutions.

Good to hear that it works OK. Sooner or later setmax or something
similar must become part of the standard kernel, but so far I've
gotten almost no feedback. Can you give the disk manufacturer and model
(mail aeb@cwi.nl)?

Andries

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 16:38 2.4.x kernels, big ide disks and old bios Andries.Brouwer
@ 2001-12-25 22:52 ` Eric Lammerts
  2001-12-26  9:28   ` Josep Lladonosa i Capell
  2001-12-26 10:39 ` Santiago Garcia Mantinan
  1 sibling, 1 reply; 19+ messages in thread
From: Eric Lammerts @ 2001-12-25 22:52 UTC (permalink / raw)
  To: Andries.Brouwer; +Cc: jlladono, linux-kernel


On Tue, 25 Dec 2001 Andries.Brouwer@cwi.nl wrote:
> : What I'm using is change the geometry after the boot and before any
> : partition besides root is mounted, I do this at the beginning of
> : checkroot.sh by calling "/sbin/setmax -d 0 /dev/hda"
> : This works ok for me, of course you can have other solutions.
>
> Good to hear that it works OK. Sooner or later setmax or something
> similar must become part of the standard kernel, but so far I've
> gotten almost no feedback. Can you give the disk manufacturer and model
> (mail aeb@cwi.nl)?

The kernel part is already there in Andre Hedrick's IDE-patches for
2.2.x and 2.4.x. I don't know why it's not in standard 2.4.x.

Patch below is for 2.4.x, extracted from Andre's code. Works For Me(tm).

Eric


--- linux/drivers/ide/ide-disk.c~	Fri Oct 27 08:35:48 2000
+++ linux/drivers/ide/ide-disk.c	Sun Jan  7 23:04:57 2001
@@ -513,24 +513,149 @@
 			current_capacity(drive));
 }

+
+/*
+ * Tests if the drive supports Host Protected Area feature.
+ * Returns true if supported, false otherwise.
+ */
+static inline int idedisk_supports_host_protected_area(ide_drive_t *drive)
+{
+ int flag = (drive->id->command_set_1 & 0x0400) ? 1 : 0;
+ printk("%s: host protected area => %d\n", drive->name, flag);
+ return flag;
+}
+
+/*
+ * Queries for true maximum capacity of the drive.
+ * Returns maximum LBA address (> 0) of the drive, 0 if failed.
+ */
+static unsigned long idedisk_read_native_max_address(ide_drive_t *drive)
+{
+ byte args[7];
+ unsigned long addr = 0;
+
+ printk("%s: checking for max native LBA...\n", drive->name);
+
+ /* Create IDE/ATA command request structure
+ *
+ * NOTE: I'm not sure if I can safely use IDE_*_OFFSET macro
+ * here...For real ATA command structure, offset for IDE
+ * command is 7, but in IDE driver, it needs to be at 0th
+ * index (same goes for IDE status offset below). Hmm...
+ */
+ args[0] = 0xf8; /* READ_NATIVE_MAX - see ATA spec */
+ args[IDE_FEATURE_OFFSET] = 0x00;
+ args[IDE_NSECTOR_OFFSET] = 0x00;
+ args[IDE_SECTOR_OFFSET] = 0x00;
+ args[IDE_LCYL_OFFSET] = 0x00;
+ args[IDE_HCYL_OFFSET] = 0x00;
+ args[IDE_SELECT_OFFSET] = 0x40;
+
+ /* submit command request - if OK, read current max LBA value */
+ if (ide_wait_cmd_task(drive, args) == 0) {
+ if ((args[0] & 0x01) == 0) {
+ addr = ((args[IDE_SELECT_OFFSET] & 0x0f) << 24)
+ | ((args[IDE_HCYL_OFFSET] ) << 16)
+ | ((args[IDE_LCYL_OFFSET] ) << 8)
+ | ((args[IDE_SECTOR_OFFSET] ));
+ }
+ }
+
+ printk("%s: max native LBA is %lu\n", drive->name, addr);
+
+ return addr;
+}
+
+/*
+ * Sets maximum virtual LBA address of the drive.
+ * Returns new maximum virtual LBA address (> 0) or 0 on failure.
+ */
+static unsigned long idedisk_set_max_address(ide_drive_t *drive,
+ unsigned long addr_req)
+{
+ byte args[7];
+ unsigned long addr_set = 0;
+
+ printk("%s: (un)clipping max LBA...\n", drive->name);
+
+ /* Create IDE/ATA command request structure
+ *
+ * NOTE: I'm not sure if I can safely use IDE_*_OFFSET macro
+ * here...For real ATA command structure, offset for IDE
+ * command is 7, but in IDE driver, it needs to be at 0th
+ * index (same goes for IDE status offset below). Hmm...
+ */
+ args[0] = 0xf9; /* SET_MAX - see ATA spec */
+ args[IDE_FEATURE_OFFSET] = 0x00;
+ args[IDE_NSECTOR_OFFSET] = 0x00;
+ args[IDE_SECTOR_OFFSET] = ((addr_req ) & 0xff);
+ args[IDE_LCYL_OFFSET] = ((addr_req >> 8) & 0xff);
+ args[IDE_HCYL_OFFSET] = ((addr_req >> 16) & 0xff);
+ args[IDE_SELECT_OFFSET] = ((addr_req >> 24) & 0x0f) | 0x40;
+
+ /* submit command request - if OK, read new max LBA value */
+ if (ide_wait_cmd_task(drive, args) == 0) {
+ if ((args[0] & 0x01) == 0) {
+ addr_set = ((args[IDE_SELECT_OFFSET] & 0x0f) << 24)
+ | ((args[IDE_HCYL_OFFSET] ) << 16)
+ | ((args[IDE_LCYL_OFFSET] ) << 8)
+ | ((args[IDE_SECTOR_OFFSET] ));
+ }
+ }
+
+ printk("%s: max LBA (un)clipped to %lu\n", drive->name, addr_set);
+
+ return addr_set;
+}
+
 /*
  * Compute drive->capacity, the full capacity of the drive
  * Called with drive->id != NULL.
+ *
+ * To compute capacity, this uses either of
+ *
+ * 1. CHS value set by user (whatever user sets will be trusted)
+ * 2. LBA value from target drive (require new ATA feature)
+ * 3. LBA value from system BIOS (new one is OK, old one may break)
+ * 4. CHS value from system BIOS (traditional style)
+ *
+ * in above order (i.e., if value of higher priority is available,
+ * rest of the values are ignored).
  */
 static void init_idedisk_capacity (ide_drive_t  *drive)
 {
+ unsigned long hd_max;
+ unsigned long hd_cap = drive->cyl * drive->head * drive->sect;
+ int is_lba = 0;
+
 	struct hd_driveid *id = drive->id;
-	unsigned long capacity = drive->cyl * drive->head * drive->sect;

-	drive->select.b.lba = 0;
+ /* Unless geometry is given by user, use autodetected value */
+ if (! drive->forced_geom) {
+ /* If BIOS LBA geometry is available, use it */
+ if ((id->capability & 2) && lba_capacity_is_ok(id)) {
+ hd_cap = id->lba_capacity;
+ is_lba = 1;
+ }

-	/* Determine capacity, and use LBA if the drive properly supports it */
-	if ((id->capability & 2) && lba_capacity_is_ok(id)) {
-		capacity = id->lba_capacity;
-		drive->cyl = capacity / (drive->head * drive->sect);
-		drive->select.b.lba = 1;
+ /* If new ATA feature is supported, try using it */
+ if (idedisk_supports_host_protected_area(drive)) {
+ hd_max = idedisk_read_native_max_address(drive);
+ hd_max = idedisk_set_max_address(drive, hd_max);
+
+ if (hd_max > 0) {
+ hd_cap = hd_max+1;
+ is_lba = 1;
+ }
+ }
 	}
-	drive->capacity = capacity;
+
+ printk("%s: lba = %d, cap = %lu\n", drive->name, is_lba, hd_cap);
+
+ /* update parameters with fetched results */
+ drive->select.b.lba = is_lba;
+ drive->capacity = hd_cap;
+ drive->cyl = hd_cap / (drive->head * drive->sect);
 }

 static unsigned long idedisk_capacity (ide_drive_t  *drive)


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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 22:52 ` Eric Lammerts
@ 2001-12-26  9:28   ` Josep Lladonosa i Capell
  0 siblings, 0 replies; 19+ messages in thread
From: Josep Lladonosa i Capell @ 2001-12-26  9:28 UTC (permalink / raw)
  To: Eric Lammerts; +Cc: Andries.Brouwer, linux-kernel

Eric Lammerts wrote:

> The kernel part is already there in Andre Hedrick's IDE-patches for
> 2.2.x and 2.4.x. I don't know why it's not in standard 2.4.x.

suppose first references are to 2.2.x and 2.3.x.


>
> Patch below is for 2.4.x, extracted from Andre's code. Works For Me(tm).

patch rejected for 2.4.17 kernel. Not Working For Me :-(



--
Salutacions...Josep
http://www.geocities.com/SiliconValley/Horizon/1065/
--




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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 16:38 2.4.x kernels, big ide disks and old bios Andries.Brouwer
  2001-12-25 22:52 ` Eric Lammerts
@ 2001-12-26 10:39 ` Santiago Garcia Mantinan
  1 sibling, 0 replies; 19+ messages in thread
From: Santiago Garcia Mantinan @ 2001-12-26 10:39 UTC (permalink / raw)
  To: Andries.Brouwer; +Cc: jlladono, linux-kernel, aeb

> Good to hear that it works OK. Sooner or later setmax or something
> similar must become part of the standard kernel, but so far I've
> gotten almost no feedback. Can you give the disk manufacturer and model
> (mail aeb@cwi.nl)?

Well, yes, as I had not said it on my previous mail, I'm not putting any
geometry or anything like that on lilo, the disk I have now working like
that is a 60Gigs Seagate Model=ST340823A which is recogniced by Linux as...

hda: 66055248 sectors (33820 MB) w/512KiB Cache, CHS=4111/255/63, UDMA(33)

Of course after using setmax I can access the hole disk.

I have also tried this on a 80 Gigs Seagate Model=ST380020A and it also
works ok.

Regards...
-- 
Manty/BestiaTester -> http://manty.net

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-28 21:52 ` Jorge Nerin
@ 2001-12-30  9:33   ` Josep Lladonosa i Capell
  0 siblings, 0 replies; 19+ messages in thread
From: Josep Lladonosa i Capell @ 2001-12-30  9:33 UTC (permalink / raw)
  To: Jorge Nerin; +Cc: jlladono, linux-kernel

Jorge Nerin wrote:

> I have a 486, bios (as i remember) does not even see the disk.
>
> HD is 40Gb
>
> Linux boots and works for me with no problem in this system.

Is your disk hda, not configured in the bios, and it boots?????

Perhaps you have it configured in the bios as a smaler size (8G - 32G).


--
Salutacions...Josep
http://www.geocities.com/SiliconValley/Horizon/1065/
--




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

* Re: 2.4.x kernels, big ide disks and old bios
@ 2001-12-30  2:47 Andries.Brouwer
  0 siblings, 0 replies; 19+ messages in thread
From: Andries.Brouwer @ 2001-12-30  2:47 UTC (permalink / raw)
  To: jlladono; +Cc: linux-kernel

> # cat /proc/ide/hdc/settings
> name                    value           min             max             mode
> ----                    -----           ---             ---             ----
> bios_cyl                119150          0               65535           rw
> bios_head               16              0               255             rw
> bios_sect               63              0               63              rw

> What's the meaning of the 65535 max limit in bios_cyl?

It is meaningless.

(Maybe there was some meaning long ago, for example because
HDIO_GETGEO only uses a 16-bit field for #cyls.
These days bios_cyl is not used anywhere. Not in the kernel,
not in user space. It is just some random number, computed
by taking disk-size / (heads*secs).)

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-28  3:29         ` Andre Hedrick
@ 2001-12-30  1:40           ` Josep Lladonosa i Capell
  0 siblings, 0 replies; 19+ messages in thread
From: Josep Lladonosa i Capell @ 2001-12-30  1:40 UTC (permalink / raw)
  To: Andre Hedrick
  Cc: Stephan von Krawczynski, Guest section DW, James Stevenson,
	jlladono, linux-kernel

Andre Hedrick wrote:

> You have it called "STROKE".
>
> Use a patch and execute a soft-clip operation to the device and you are
> fixed.

...depends. I want the big disk to be /dev/hda, and bootable (an unattended
boot).

Disk is  119150/16/63. I soft (un)clipped it to max capacity (60Gb) with setmax
.

Configured it in the bios (32Gb limit) as a smaller disk, bios complained,
telling an error, asking to press F1 to continue. The LBA mode (4111/255/63,
LBA, for example) told the error, and asking for F1, as well. With
(65530/16/63, NORM), it booted well.
Kernel (2.4.17, patched) corrected the geometry while booting, but mke2fs
generated many io-errors, I suspect beyond the 32Gb.

Finally, a bios upgrade (unfortunately not for sizes beyond 32Gb), let me to
configure the setup with
the LBA mode, and boot works well, and mke2fs doesn't complain.

I don't need to use setmax to clip-unclip when booting.

What's the meaning of the 65535 max limit in bios_cyl? *

*I don't think it is a kernel limit.
*Is it the max value accepted by the physical disk, and that's why lba is used?

*Was that the problem with the io-errors?


# cat /proc/ide/hdc/settings
name                    value           min             max             mode
----                    -----           ---             ---             ----
bios_cyl                119150          0               65535           rw
bios_head               16              0               255             rw
bios_sect               63              0               63              rw


--
Salutacions...Josep
http://www.geocities.com/SiliconValley/Horizon/1065/
--




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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 10:56 Josep Lladonosa i Capell
                   ` (2 preceding siblings ...)
  2001-12-26 16:33 ` Stephan von Krawczynski
@ 2001-12-28 21:52 ` Jorge Nerin
  2001-12-30  9:33   ` Josep Lladonosa i Capell
  3 siblings, 1 reply; 19+ messages in thread
From: Jorge Nerin @ 2001-12-28 21:52 UTC (permalink / raw)
  To: jlladono; +Cc: linux-kernel

Josep Lladonosa i Capell wrote:

> Hello,
> 
> the problem is this:
> 
> bios only supports disks up to 32 Gb.


I have a 486, bios (as i remember) does not even see the disk.


> 
> hard disk is 60 Gb.


HD is 40Gb


> 
> kernel is 2.4.17
> 

2.4.15-pre9 + tux2 patches


> hard disk reports its correct size when reading parameters from the
> disk, not from the bios
> 
> verd:/proc/ide/hdc# cat geometry
> physical     65530/16/63
> logical      119150/16/63
> 


[root@head (22:45:56) ~]# cat /proc/ide/hda/geometry
physical     77545/16/63
logical      77545/16/63
[root@head (22:46:07) ~]#


> 
> when booting (dmesg):
> 
> hdc: IC35L060AVER07-0, ATA DISK drive
> hdc: 66055247 sectors (33820 MB) w/1916KiB Cache, CHS=119150/16/63,
> UDMA(33)
> 
> 


hda: 78165360 sectors (40021 MB) w/1024KiB Cache, CHS=77545/16/63


> Linux adopts the 'false' geometry (65530/16/63) ) to bypass the bios
> boot.
> 
> 


All I can say is that I have a /boot partition of about 64 Megs, because 
I have / formated as reiser so /boot is ext2 because it's from the time 
that you cannot boot from reiser without notail.


> 
> I know that there are patches for 2.2 kernels and 2.3 kernels, so as
> linux adopts the logical geometry (a kiddy trick with lba size). They
> are very simple (a line), but 2.4 ide implementation is (a little more)
> complicated. Any patch?
> 


Well, it works for me, and as I have said, I have a 486, I'm not sure if 
the bios supports this size, but I seem to remember that it even does 
not detect it at boot, or perhaps it detects it as a strange size such 
as 8Gb or 32Gb, just don't remember.

Linux boots and works for me with no problem in this system.


> Bon Nadal - Merry Christmas
> 


Feliz Navidad.


> --
> Salutacions...Josep
> http://www.geocities.com/SiliconValley/Horizon/1065/



-- 
Jorge Nerin
<comandante@zaralinux.com>


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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-27 23:04       ` Stephan von Krawczynski
@ 2001-12-28  3:29         ` Andre Hedrick
  2001-12-30  1:40           ` Josep Lladonosa i Capell
  0 siblings, 1 reply; 19+ messages in thread
From: Andre Hedrick @ 2001-12-28  3:29 UTC (permalink / raw)
  To: Stephan von Krawczynski
  Cc: Guest section DW, James Stevenson, jlladono, linux-kernel


You have it called "STROKE".

Use a patch and execute a soft-clip operation to the device and you are
fixed.  To bad the kernel maintainers do not see value in this or any
other driver that follows the standards for the physical layers.

Regards,

On Fri, 28 Dec 2001, Stephan von Krawczynski wrote:

> > On Thu, Dec 27, 2001 at 07:51:01PM +0100, Stephan von Krawczynski   
> wrote:                                                                
> >                                                                     
> > > I don't know. I tried once with                                   
> > >                                                                   
> > > 00:01.1 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE]
> (rev d0)                                                              
> > >                                                                   
> > > and it did not work. I could definitely not write beyond the 32 GB
> border. I                                                             
> > > replaced the mobo then.                                           
> >                                                                     
> > Did you try setmax?                                                 
>                                                                       
> unfortunately not, I did not even know it existed before this thread. 
> I must admit I have still not had a look at it, but on the other hand:
> if it makes big IDE drives work on old mobo & bios, it may be a good  
> idea to include its intelligence into the kernel, or not?             
> Yes, I know that people nowadays tend to strip down _old_ stuff from  
> the current sources, but I guess it is not a big loss in code size    
> either, is it?                                                        
> knock, knock .. hello IDE maintainer, how about a Xmas present ?      
> :-)                                                                   
>                                                                       
> Regards,                                                              
> Stephan                                                               
>                                                                       
>                                                                       
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 

Andre Hedrick
CEO/President, LAD Storage Consulting Group
Linux ATA Development
Linux Disk Certification Project


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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-27 22:41     ` Guest section DW
@ 2001-12-27 23:04       ` Stephan von Krawczynski
  2001-12-28  3:29         ` Andre Hedrick
  0 siblings, 1 reply; 19+ messages in thread
From: Stephan von Krawczynski @ 2001-12-27 23:04 UTC (permalink / raw)
  To: Guest section DW; +Cc: James Stevenson, jlladono, linux-kernel

> On Thu, Dec 27, 2001 at 07:51:01PM +0100, Stephan von Krawczynski   
wrote:                                                                
>                                                                     
> > I don't know. I tried once with                                   
> >                                                                   
> > 00:01.1 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE]
(rev d0)                                                              
> >                                                                   
> > and it did not work. I could definitely not write beyond the 32 GB
border. I                                                             
> > replaced the mobo then.                                           
>                                                                     
> Did you try setmax?                                                 
                                                                      
unfortunately not, I did not even know it existed before this thread. 
I must admit I have still not had a look at it, but on the other hand:
if it makes big IDE drives work on old mobo & bios, it may be a good  
idea to include its intelligence into the kernel, or not?             
Yes, I know that people nowadays tend to strip down _old_ stuff from  
the current sources, but I guess it is not a big loss in code size    
either, is it?                                                        
knock, knock .. hello IDE maintainer, how about a Xmas present ?      
:-)                                                                   
                                                                      
Regards,                                                              
Stephan                                                               
                                                                      
                                                                      

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-27 18:51   ` Stephan von Krawczynski
  2001-12-27 19:53     ` Ido Diamant
@ 2001-12-27 22:41     ` Guest section DW
  2001-12-27 23:04       ` Stephan von Krawczynski
  1 sibling, 1 reply; 19+ messages in thread
From: Guest section DW @ 2001-12-27 22:41 UTC (permalink / raw)
  To: Stephan von Krawczynski, James Stevenson; +Cc: jlladono, linux-kernel

On Thu, Dec 27, 2001 at 07:51:01PM +0100, Stephan von Krawczynski wrote:

> I don't know. I tried once with
> 
> 00:01.1 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev d0)
> 
> and it did not work. I could definitely not write beyond the 32 GB border. I
> replaced the mobo then.

Did you try setmax?

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-27 18:51   ` Stephan von Krawczynski
@ 2001-12-27 19:53     ` Ido Diamant
  2001-12-27 22:41     ` Guest section DW
  1 sibling, 0 replies; 19+ messages in thread
From: Ido Diamant @ 2001-12-27 19:53 UTC (permalink / raw)
  To: Stephan von Krawczynski; +Cc: James Stevenson, jlladono, linux-kernel

Hi,

I am having an old Pentium 120, with an old BIOS.
I got new 40GB hard disk, and in order to make it readable, I needed to
use the cable-select jumper in order to make the hard disk look smaller
for the bios.
The only problem is that the linux recognizes my hard drive as 33GB (maybe
its 32 as you said). will what you said about disabling the hard disk
recognision at the BIOS help me?
I don't want to play with the BIOS for nothing, so please let me know.

 Thanks,
   Ido

On Thu, 27 Dec 2001, Stephan von Krawczynski wrote:

> On Thu, 27 Dec 2001 13:14:43 -0000
> "James Stevenson" <mistral@stev.org> wrote:
>
> > > I tried this one some time ago, and had to find out, that I was not able
> > to
> > > write to the upper cylinders of the disk. You can check this out _before_
> > using
> > > the drive via dd from /dev/zero to your /dev/drive and look at the
> > results.
> >
> > it seems to work fine for me.
> > could it be possible that the chipset that you are using does not support
> > disks bigger than 32GB ?
>
> I don't know. I tried once with
>
> 00:01.1 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev d0)
>
> and it did not work. I could definitely not write beyond the 32 GB border. I
> replaced the mobo then.
>
> Regards,
> Stephan
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
>


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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-26 16:33 ` Stephan von Krawczynski
  2001-12-27 13:14   ` James Stevenson
@ 2001-12-27 18:51   ` Stephan von Krawczynski
  2001-12-27 19:53     ` Ido Diamant
  2001-12-27 22:41     ` Guest section DW
  1 sibling, 2 replies; 19+ messages in thread
From: Stephan von Krawczynski @ 2001-12-27 18:51 UTC (permalink / raw)
  To: James Stevenson; +Cc: jlladono, linux-kernel

On Thu, 27 Dec 2001 13:14:43 -0000
"James Stevenson" <mistral@stev.org> wrote:

> > I tried this one some time ago, and had to find out, that I was not able
> to
> > write to the upper cylinders of the disk. You can check this out _before_
> using
> > the drive via dd from /dev/zero to your /dev/drive and look at the
> results.
> 
> it seems to work fine for me.
> could it be possible that the chipset that you are using does not support
> disks bigger than 32GB ?

I don't know. I tried once with

00:01.1 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev d0)

and it did not work. I could definitely not write beyond the 32 GB border. I
replaced the mobo then.

Regards,
Stephan


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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-26 16:33 ` Stephan von Krawczynski
@ 2001-12-27 13:14   ` James Stevenson
  2001-12-27 18:51   ` Stephan von Krawczynski
  1 sibling, 0 replies; 19+ messages in thread
From: James Stevenson @ 2001-12-27 13:14 UTC (permalink / raw)
  To: Stephan von Krawczynski; +Cc: jlladono, linux-kernel



> > my workaround:
> >
> > dont set the jumper on the disk to make it look smaller.
> > this however will stop it working in the bios so you need to
> > disable the disk in the bios completly and turn off the ide
> > auto detection process in the bios this is because it will
> > probably hang if you try to use it :)
> >
> > linux will then pick the disk up from the ide controller.
>
> I tried this one some time ago, and had to find out, that I was not able
to
> write to the upper cylinders of the disk. You can check this out _before_
using
> the drive via dd from /dev/zero to your /dev/drive and look at the
results.

it seems to work fine for me.
could it be possible that the chipset that you are using does not support
disks bigger than 32GB ?



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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 10:56 Josep Lladonosa i Capell
  2001-12-25 14:10 ` Santiago Garcia Mantinan
  2001-12-25 19:09 ` James Stevenson
@ 2001-12-26 16:33 ` Stephan von Krawczynski
  2001-12-27 13:14   ` James Stevenson
  2001-12-27 18:51   ` Stephan von Krawczynski
  2001-12-28 21:52 ` Jorge Nerin
  3 siblings, 2 replies; 19+ messages in thread
From: Stephan von Krawczynski @ 2001-12-26 16:33 UTC (permalink / raw)
  To: James Stevenson; +Cc: jlladono, linux-kernel

On Tue, 25 Dec 2001 19:09:22 -0000
"James Stevenson" <mail-lists@stev.org> wrote:

> Hi
> 
> i have the same problem weith a 40GB disk
> its not a linux problem but a bios / disk problem
> 
> my workaround:
> 
> dont set the jumper on the disk to make it look smaller.
> this however will stop it working in the bios so you need to
> disable the disk in the bios completly and turn off the ide
> auto detection process in the bios this is because it will
> probably hang if you try to use it :)
> 
> linux will then pick the disk up from the ide controller.

I tried this one some time ago, and had to find out, that I was not able to
write to the upper cylinders of the disk. You can check this out _before_ using
the drive via dd from /dev/zero to your /dev/drive and look at the results.

Regards,
Stephan


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

* Re: 2.4.x kernels, big ide disks and old bios
@ 2001-12-26  2:12 Andries.Brouwer
  0 siblings, 0 replies; 19+ messages in thread
From: Andries.Brouwer @ 2001-12-26  2:12 UTC (permalink / raw)
  To: Andries.Brouwer, eric; +Cc: linux-kernel

> The kernel part is already there in Andre Hedrick's IDE-patches

Yes. By some coincidence this code fails on my Maxtor,
but it will work on most disks.

Andries

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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 10:56 Josep Lladonosa i Capell
  2001-12-25 14:10 ` Santiago Garcia Mantinan
@ 2001-12-25 19:09 ` James Stevenson
  2001-12-26 16:33 ` Stephan von Krawczynski
  2001-12-28 21:52 ` Jorge Nerin
  3 siblings, 0 replies; 19+ messages in thread
From: James Stevenson @ 2001-12-25 19:09 UTC (permalink / raw)
  To: jlladono, linux-kernel

Hi

i have the same problem weith a 40GB disk
its not a linux problem but a bios / disk problem

my workaround:

dont set the jumper on the disk to make it look smaller.
this however will stop it working in the bios so you need to
disable the disk in the bios completly and turn off the ide
auto detection process in the bios this is because it will
probably hang if you try to use it :)

linux will then pick the disk up from the ide controller.

----- Original Message -----
From: "Josep Lladonosa i Capell" <jep@jep.net.dhis.org>
To: <linux-kernel@vger.kernel.org>
Sent: Tuesday, December 25, 2001 10:56 AM
Subject: 2.4.x kernels, big ide disks and old bios


> Hello,
>
> the problem is this:
>
> bios only supports disks up to 32 Gb.
>
> hard disk is 60 Gb.
>
> kernel is 2.4.17
>
> hard disk reports its correct size when reading parameters from the
> disk, not from the bios
>
> verd:/proc/ide/hdc# cat geometry
> physical     65530/16/63
> logical      119150/16/63
>
>
> when booting (dmesg):
>
> hdc: IC35L060AVER07-0, ATA DISK drive
> hdc: 66055247 sectors (33820 MB) w/1916KiB Cache, CHS=119150/16/63,
> UDMA(33)
>
>
> Linux adopts the 'false' geometry (65530/16/63) ) to bypass the bios
> boot.
>
>
>
> I know that there are patches for 2.2 kernels and 2.3 kernels, so as
> linux adopts the logical geometry (a kiddy trick with lba size). They
> are very simple (a line), but 2.4 ide implementation is (a little more)
> complicated. Any patch?
>
> Bon Nadal - Merry Christmas
>
> --
> Salutacions...Josep
> http://www.geocities.com/SiliconValley/Horizon/1065/
> --
>
>
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/



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

* Re: 2.4.x kernels, big ide disks and old bios
  2001-12-25 10:56 Josep Lladonosa i Capell
@ 2001-12-25 14:10 ` Santiago Garcia Mantinan
  2001-12-25 19:09 ` James Stevenson
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 19+ messages in thread
From: Santiago Garcia Mantinan @ 2001-12-25 14:10 UTC (permalink / raw)
  To: jlladono; +Cc: linux-kernel

> bios only supports disks up to 32 Gb.
> hard disk is 60 Gb.

What I'm using is change the geometry after the boot and before any
partition besides root is mounted, I do this at the beginning of
checkroot.sh by calling "/sbin/setmax -d 0 /dev/hda" but you can do it on
your own script or where ever you want, just taking care that it is done
befor any FS that goes above the 32gigs is accessed.

Setmax is a small program that I downloaded from the net, sorry, I don't
remember where did I download it from or his author, but it was posted to
this list some time ago, I have a version for the 2.4 kernel at
ftp.manty.net/linux/programs/setmax.c

This works ok for me, of course you can have other solutions.

Regards...
-- 
Manty/BestiaTester -> http://manty.net

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

* 2.4.x kernels, big ide disks and old bios
@ 2001-12-25 10:56 Josep Lladonosa i Capell
  2001-12-25 14:10 ` Santiago Garcia Mantinan
                   ` (3 more replies)
  0 siblings, 4 replies; 19+ messages in thread
From: Josep Lladonosa i Capell @ 2001-12-25 10:56 UTC (permalink / raw)
  To: linux-kernel

Hello,

the problem is this:

bios only supports disks up to 32 Gb.

hard disk is 60 Gb.

kernel is 2.4.17

hard disk reports its correct size when reading parameters from the
disk, not from the bios

verd:/proc/ide/hdc# cat geometry
physical     65530/16/63
logical      119150/16/63


when booting (dmesg):

hdc: IC35L060AVER07-0, ATA DISK drive
hdc: 66055247 sectors (33820 MB) w/1916KiB Cache, CHS=119150/16/63,
UDMA(33)


Linux adopts the 'false' geometry (65530/16/63) ) to bypass the bios
boot.



I know that there are patches for 2.2 kernels and 2.3 kernels, so as
linux adopts the logical geometry (a kiddy trick with lba size). They
are very simple (a line), but 2.4 ide implementation is (a little more)
complicated. Any patch?

Bon Nadal - Merry Christmas

--
Salutacions...Josep
http://www.geocities.com/SiliconValley/Horizon/1065/
--




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

end of thread, other threads:[~2001-12-30  9:34 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-12-25 16:38 2.4.x kernels, big ide disks and old bios Andries.Brouwer
2001-12-25 22:52 ` Eric Lammerts
2001-12-26  9:28   ` Josep Lladonosa i Capell
2001-12-26 10:39 ` Santiago Garcia Mantinan
  -- strict thread matches above, loose matches on Subject: below --
2001-12-30  2:47 Andries.Brouwer
2001-12-26  2:12 Andries.Brouwer
2001-12-25 10:56 Josep Lladonosa i Capell
2001-12-25 14:10 ` Santiago Garcia Mantinan
2001-12-25 19:09 ` James Stevenson
2001-12-26 16:33 ` Stephan von Krawczynski
2001-12-27 13:14   ` James Stevenson
2001-12-27 18:51   ` Stephan von Krawczynski
2001-12-27 19:53     ` Ido Diamant
2001-12-27 22:41     ` Guest section DW
2001-12-27 23:04       ` Stephan von Krawczynski
2001-12-28  3:29         ` Andre Hedrick
2001-12-30  1:40           ` Josep Lladonosa i Capell
2001-12-28 21:52 ` Jorge Nerin
2001-12-30  9:33   ` Josep Lladonosa i Capell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).