Dear Genodians,
Here are two (very minor) notes after my upgrading to 23.02 (plus 
cherry-picking the patch from #4785),
regarding two "bugs" I had found, which ended up being mistakes on my side, not 
on Genode's side.

These two don't justify opening tickets, but they might deserve a quick mention 
here on the mailing-list:

* vfs_pipe: components that use the "pipe" plug-in should make sure to enable 
RTC (<libc rtc="/dev/rtc"...>)
as of 23.02 -- previously it would work without specifying an RTC path. This 
probably has zero impact
since everyone properly configures their libc config (unlike me in the one 
scenario that brought this up..!)

* FS "stalls" when a vfs-handle fails read()ing in a specific way:
Found out that when writing a vfs plug-in, and vfs handles, I ought to make 
sure not to return READ_ERR in the read() hook,
error cases should be detected earlier, at the open() stage (-> return a nil 
vfs-handle and error code, obviously).
Once a valid vfs-handle is returned in open() it's not ok to say "sorry, my 
bad, the file cannot actually
be read and should not have been opened in the first place" every time read() 
is called... Otherwise this entails
a bunch of consequences, the most visible of which is big red "packet operation 
failed" error messages in the LOG !
Again, others seem more careful, but I stumbled into making that mistake and 
thought I should post a cautionary tale about it ;-)

Cédric

P.S. If one is in need of a quick temporary hack before vfs-handle usage is 
cleaned up, it seems there is an alternative way
for the stalls to be kept at bay or mitigated by modifying Genode's 
fs_file_system.h, adding a forced call to wakeup_vfs_user()
(I'm still investigating... hopefully won't have to dig much though, fixing my 
code to fail earlier at the open() stage should do the trick).





_______________________________________________
Genode users mailing list
[email protected]
https://lists.genode.org/listinfo/users

Reply via email to