Re: How to know the file size limit, and know if O_DIRECT is supported

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Manish Regmi,
My colleague said he doesn't know it the buffer start address and size are
aligning the block size.
I'll make the test next week... :-)

Thanks and regards,
Colin



----- Original Message ----- 
From: "Manish Regmi" <regmi.manish@xxxxxxxxx>
To: "colin" <colin@xxxxxxxxxxxxxx>
Cc: <kernelnewbies@xxxxxxxxxxxx>
Sent: Friday, December 22, 2006 1:26 PM
Subject: Re: How to know the file size limit, and know if O_DIRECT is
supported


> On 12/22/06, colin <colin@xxxxxxxxxxxxxx> wrote:
> >
> > Hi Erik,
> > My colleague said that when use direct I/O on USB disk that has a ext3
> > partition, open can succeed, but read fails.
> > I know that filesystem must have some system calls for direct I/O, and
open
> > with O_DIRECT flag will check if these system calls exist.
> > But why does read fail? Is it that direst I/O cannot use on USB disk?
>
> Have you aligned the buffers correctly. Read/Write will fail if buffer
> is not aligned in sector boundry.
>
> -- 
> ---------------------------------------------------------------
> regards
> Manish Regmi
>
> ---------------------------------------------------------------
> UNIX without a C Compiler is like eating Spaghetti with your mouth
> sewn shut. It just doesn't make sense.


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux