From mboxrd@z Thu Jan 1 00:00:00 1970 From: "David H. Lynch Jr." Subject: Read/write counts Date: Mon, 04 Jun 2007 06:20:42 -0400 Message-ID: <4663E77A.9040802@comcast.net> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit To: linux-fsdevel@vger.kernel.org Return-path: Received: from alnrmhc12.comcast.net ([206.18.177.52]:57952 "EHLO alnrmhc12.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751311AbXFDKUn (ORCPT ); Mon, 4 Jun 2007 06:20:43 -0400 Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org I have a file system that has really odd blocking. All files have a variable length header (basically a directory entry) at their start. Most but not all sectors, have a small fixed length signature as well as some link data at their start. The net result is that implimentation would be simpler if I could just read/write, the amount of data that can be done with the least amount of work, even if that is less than was requested. If I receive a request to read 512 bytes, and I return that I have read 486, is either the OS, libc, or something else going to treat that as an error, or are they coming back for the rest in a subsequent call ? I though I recalled that read()/write() returning a cound less than requested is not an error.