mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Daniel Palmer <daniel@thingy.jp>
To: w@1wt.eu, linux@weissschuh.net
Cc: david.laight.linux@gmail.com, linux-kernel@vger.kernel.org,
	Daniel Palmer <daniel@thingy.jp>
Subject: [PATCH v2 0/3] nolibc: Add fread() and fseek()
Date: Mon,  5 Jan 2026 11:36:26 +0900	[thread overview]
Message-ID: <20260105023629.1502801-1-daniel@thingy.jp> (raw)

v1 blurb:

Using nolibc on nommu 68000, something I'm trying to build[0] wanted fread() and fseek()
so I added them, they seem to work so I'm sharing them. Not sure if I need to add
tests or something? Maybe there is a reason these weren't implemented in the first place...

0 - https://github.com/FrenkelS/Doom8088ST/issues/21

Changelog:
v2:
- A few style clean ups in fread() requested by Thomas.
- Added a basic test that exercises the new functions. This isn't a complete POSIX
  testsuite, just a very basic smoke test. I couldn't think of proper error numbers
  for different failure cases (Suggested by Thomas), any ideas appreciated.

Daniel Palmer (3):
  tools/nolibc: Add fread() to stdio.h
  tools/nolibc: Add fseek() to stdio.h
  tools/nolibc: Add a simple test for writing to a FILE and reading it
    back

 tools/include/nolibc/stdio.h                 | 53 +++++++++++++++++++-
 tools/testing/selftests/nolibc/nolibc-test.c | 53 ++++++++++++++++++++
 2 files changed, 105 insertions(+), 1 deletion(-)

-- 
2.51.0


             reply	other threads:[~2026-01-05  2:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-05  2:36 Daniel Palmer [this message]
2026-01-05  2:36 ` [PATCH v2 1/3] tools/nolibc: Add fread() to stdio.h Daniel Palmer
2026-01-05  2:36 ` [PATCH v2 2/3] tools/nolibc: Add fseek() " Daniel Palmer
2026-01-05  2:36 ` [PATCH v2 3/3] tools/nolibc: Add a simple test for writing to a FILE and reading it back Daniel Palmer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260105023629.1502801-1-daniel@thingy.jp \
    --to=daniel@thingy.jp \
    --cc=david.laight.linux@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@weissschuh.net \
    --cc=w@1wt.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®