Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: Harald Koenig <koenig@tat.physik.uni-tuebingen.de>
Subject: Re: sys_lseek() broken for alpha
Date: Tue, 14 May 1996 11:38:24 +0200 (MET DST)	[thread overview]
Message-ID: <9605140958.AA29039@nova.tat.physik.uni-tuebingen.de> (raw)
In-Reply-To: <199605140011.BAA00734@dax.dcs.ed.ac.uk>

> > sys_lseek() should return off_t which is long (64 bit) for alpha but
> > returns 32bit int.  as a result, fdisk fails for >2GB disks.
> 
> Go and complain to your friendly ANSI / K&R / POSIX guru. :(  I'm
> afraid that the return type NEEDS to be int for compliance with the
> world's libc standards.  

I don't have any POSIX docs and ANSI-C (1989) says nothing about lseek().
K&R 2nd edition page 175 top even says:

	long lseek(int fd, long offset, int origin);

and DEC Unix unistd.h and sys/types.h say

	extern off_t lseek __((int , off_t , int ));
	typedef long    off_t;                  /* file offset */

also the libc-linux man page and include files mention

       off_t lseek(int fildes, off_t offset, int whence);

so I'd say I've to complain to Linus ?

> That's precisely why we need sys_llseek() on
> the intel platform to get 64-bit partition access.

this is true for 32 bit platforms like Intel but IMHO it's not true
for 64 bit architectures (here: DEC ALpha AXP)

Harald

-- 
All SCSI disks will from now on                     ___       _____
be required to send an email notice                0--,|    /OOOOOOO\
24 hours prior to complete hardware failure!      <_/  /  /OOOOOOOOOOO\
                                                    \  \/OOOOOOOOOOOOOOO\
                                                      \ OOOOOOOOOOOOOOOOO|//
Harald Koenig,                                         \/\/\/\/\/\/\/\/\/
Inst.f.Theoret.Astrophysik                              //  /     \\  \
koenig@tat.physik.uni-tuebingen.de                     ^^^^^       ^^^^^

       reply	other threads:[~1996-05-14  9:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <199605140011.BAA00734@dax.dcs.ed.ac.uk>
1996-05-14  9:38 ` Harald Koenig [this message]
1996-05-14 21:08 ` sys_lseek() broken for alpha Chris Griffin
     [not found] <Pine.SOL.3.91.960514170705.22221A-100000@vanadium>
1996-05-14 21:39 ` Harald Koenig
1996-05-13 15:35 Harald Koenig
1996-05-14  0:11 ` Stephen C. Tweedie
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox