Re: dummy file read periodically for external USB Hard Disk

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

 



On 07/18/2014 10:31 AM, loody wrote:
> hi Randy and All:
> 
>>
>> It means that the <buffer> still is not aligned to a 512-byte boundary.
>> Try
>>    char buffer[1024] __attribute__ ((aligned(1024)));
>>
>> Well, that is aligned to 1024 bytes, not 512, but whatever.
> the suggestion you gave to me works ^^
> is there any alignment check in kernel FS such that it will directly
> output to device instead of getting data from page cache?

Not sure that I understand your question, but I think that using
O_DIRECT in the open() call attempts to do what you are asking.

Please read 'man open' and search for O_DIRECT.

-- 
~Randy
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux