LWN: Comments on "Safe seeks" https://lwn.net/Articles/97154/ This is a special feed containing comments posted to the individual LWN article titled "Safe seeks". en-us Wed, 15 Jan 2025 22:40:35 +0000 Wed, 15 Jan 2025 22:40:35 +0000 https://www.rssboard.org/rss-specification lwn@lwn.net Safe seeks https://lwn.net/Articles/130694/ https://lwn.net/Articles/130694/ amw "this patch represents a change in how device drivers should be written, but the actual API has not been changed in any incompatible ways. Unmodified drivers will still work - at least, as well as they did before."<br> This is not true, at least it wasn't true of my driver and neither will it be true of any other driver including the "if (ppos != &amp;filp-&gt;f_pos) return -ESPIPE;" code fragment quoted (which I, and presumably many others orginally got from Rubini &amp; Corbet's "Linux Device Drivers", 2nd edition, p164). Until recently, all users of my driver had 2.6.5 kernels or earlier, then someone started using 2.6.8 and my driver broke, returning Illegal Seek on every write. Now I've toned down my test to "if (*ppos != filp-&gt;f_pos) return -ESPIPE;", but you shouldn't claim that "the actual API has not been changed in any incompatible ways. Unmodified drivers will still work" when the semantics of the well established relationship between the filp &amp; ppos arguments has changed.<br> Wed, 06 Apr 2005 16:29:44 +0000 Safe seeks https://lwn.net/Articles/97750/ https://lwn.net/Articles/97750/ pimlott Best article title ever.<br> Fri, 13 Aug 2004 03:16:12 +0000