Re: set blksize of block device

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

 



> >> I am learning block device drivers and have a newbie question. Given 
> >> a block device, is there anyway that I could set its block size? For 
> >> example, I want to write a block device driver that will work on an 
> >> existing block device.  In this driver, I want block size smaller. 
> >> (The idea looks confusing but I could explain if anybody is 
> >> interested :- )  However,  typically the block size is 1KB, now I 
> >> want to set it to 512 or 256.  Can I do it?

256 - no way if hardware can do only 512-byte writes.

You need read-modify-write for this.
--
vda


--
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