May 1, 2019
12:06 p.m.
my guess is your are not returning EOF (= 0). User space expects a return value of 0 (EOF) to terminate reading. But your code will always return sizeof("Hello world\n"). A fix would be to not only increment ppos, but also check if it's already behind your data.
Regards,
Martin
Thank you, Martin, help much appreciated. It's a bit of a mystery but neither works for me. More detail in my reply to Greg KH.