rust-for-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sven Van Asbroeck <thesven73@gmail.com>
To: Geert Stappers <stappers@stappers.nl>
Cc: rust-for-linux@vger.kernel.org
Subject: Re: [RFC] Short Circuit simplest Rust driver that touches real hardware?
Date: Mon, 26 Apr 2021 17:11:54 -0400	[thread overview]
Message-ID: <CAGngYiU2xze8Fo47Hbmu5CDh5VL-K4ddL-ez7+jOUTBJHydChw@mail.gmail.com> (raw)
In-Reply-To: <20210426205810.sahdkjyeueg3miug@gpm.stappers.nl>

Hi Geert,

On Mon, Apr 26, 2021 at 4:58 PM Geert Stappers <stappers@stappers.nl> wrote:
>
> Hope that hardware manufactures see this opportunity.  Because I fear that
> this cool project might get botched due lack of knowledge on hardware.
>

Thanks for your input. Would you be able to elaborate why we lack
knowledge on these Raspberry Pi peripherals? Take the rng. When
reading its driver here:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/char/hw_random/bcm2835-rng.c?h=v5.12#n62

it appears to be the case that the h/w is setup by writing a value to
two registers (RNG_STATUS, RNG_CTRL). Random data can then be read by
monitoring RNG_STATUS followed by a read from RNG_DATA.

Should be as simple as they come, no? What am I missing?

>
> Implementing kernel module for 8250 UART in Rust is something that
> wouldn't get botched due lack of hardware knowledge.

That's true, but also much more complex. Doesn't it depend on clocks
and interrupts? That's infrastructure we don't yet have in Rust.

  reply	other threads:[~2021-04-26 21:12 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-26 19:47 Sven Van Asbroeck
2021-04-26 20:22 ` Miguel Ojeda
2021-04-26 20:58 ` Geert Stappers
2021-04-26 21:11   ` Sven Van Asbroeck [this message]
2021-04-27  8:17     ` Geert Stappers
2021-04-27  6:49   ` Greg KH

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=CAGngYiU2xze8Fo47Hbmu5CDh5VL-K4ddL-ez7+jOUTBJHydChw@mail.gmail.com \
    --to=thesven73@gmail.com \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=stappers@stappers.nl \
    --subject='Re: [RFC] Short Circuit simplest Rust driver that touches real hardware?' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).