linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Nicholas Piggin" <npiggin@gmail.com>
To: "Paul Mackerras" <paulus@ozlabs.org>, <linuxppc-dev@lists.ozlabs.org>
Subject: Re: [PATCH 2/5] powerpc/microwatt: Device-tree updates
Date: Wed, 29 Jan 2025 16:36:14 +1000	[thread overview]
Message-ID: <D7ECKPNWAU7O.39PRDJ4PIG0P9@gmail.com> (raw)
In-Reply-To: <Z5lfmZtfHD7t2IvK@thinks.paulus.ozlabs.org>

On Wed Jan 29, 2025 at 8:52 AM AEST, Paul Mackerras wrote:
> Microwatt now implements ISA v3.1 (SFFS compliancy subset), including
> prefixed instructions, scv/rfscv, and the FSCR, HFSCR, TAR, and CTRL
> registers.  The privileged mode of operation is now hypervisor mode
> and there is no privileged non-hypervisor mode; the MSR[HV] bit is
> forced to 1.

Cool. Lots of development in microwatt.

Come to think of it we should have put a broadcast-tlbie feature
in there and you wouldn't need the other patch. That can go on
the todo list I guess.

system-call-vectored was available in ISA v3.0. Not that we do much
with it at the moment IIRC, but there were dreams of wiring it in for
compat guests. With that fixed,

Acked-by: Nicholas Piggin <npiggin@gmail.com>

Thanks,
Nick

>
> Besides updating the ibm,powerpc-cpu-features property to reflect the
> above, this also makes the following changes relating to peripheral
> devices:
>
> - Add gpio controller.
> - Remove high-speed property from SD controller, for the case where
>   the interface is connected through 200 ohm protection resisters.
> - Put an alias for the ethernet in /chosen.
>
> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
> ---
>  arch/powerpc/boot/dts/microwatt.dts | 73 ++++++++++++++++++++++++-----
>  1 file changed, 62 insertions(+), 11 deletions(-)
>
> diff --git a/arch/powerpc/boot/dts/microwatt.dts b/arch/powerpc/boot/dts/microwatt.dts
> index 269e930b3b0b..6e575e841a7b 100644
> --- a/arch/powerpc/boot/dts/microwatt.dts
> +++ b/arch/powerpc/boot/dts/microwatt.dts
> @@ -1,4 +1,5 @@
>  /dts-v1/;
> +#include <dt-bindings/gpio/gpio.h>
>  
>  / {
>  	#size-cells = <0x02>;
> @@ -8,6 +9,7 @@ / {
>  
>  	aliases {
>  		serial0 = &UART0;
> +		ethernet = &enet0;
>  	};
>  
>  	reserved-memory {
> @@ -35,40 +37,79 @@ cpus {
>  
>  		ibm,powerpc-cpu-features {
>  			display-name = "Microwatt";
> -			isa = <3000>;
> +			isa = <3010>;
>  			device_type = "cpu-features";
>  			compatible = "ibm,powerpc-cpu-features";
>  
>  			mmu-radix {
>  				isa = <3000>;
> -				usable-privilege = <2>;
> +				usable-privilege = <6>;
> +				os-support = <0>;
>  			};
>  
>  			little-endian {
> -				isa = <2050>;
> -				usable-privilege = <3>;
> +				isa = <0>;
> +				usable-privilege = <7>;
> +				os-support = <0>;
>  				hwcap-bit-nr = <1>;
>  			};
>  
>  			cache-inhibited-large-page {
> -				isa = <2040>;
> -				usable-privilege = <2>;
> +				isa = <0>;
> +				usable-privilege = <6>;
> +				os-support = <0>;
>  			};
>  
>  			fixed-point-v3 {
>  				isa = <3000>;
> -				usable-privilege = <3>;
> +				usable-privilege = <7>;
>  			};
>  
>  			no-execute {
> -				isa = <2010>;
> +				isa = <0x00>;
>  				usable-privilege = <2>;
> +				os-support = <0>;
>  			};
>  
>  			floating-point {
> +				hfscr-bit-nr = <0>;
>  				hwcap-bit-nr = <27>;
>  				isa = <0>;
> -				usable-privilege = <3>;
> +				usable-privilege = <7>;
> +				hv-support = <1>;
> +				os-support = <0>;
> +			};
> +
> +			prefixed-instructions {
> +				hfscr-bit-nr = <13>;
> +				fscr-bit-nr = <13>;
> +				isa = <3010>;
> +				usable-privilege = <7>;
> +				os-support = <1>;
> +				hv-support = <1>;
> +			};
> +
> +			tar {
> +				hfscr-bit-nr = <8>;
> +				fscr-bit-nr = <8>;
> +				isa = <2070>;
> +				usable-privilege = <7>;
> +				os-support = <1>;
> +				hv-support = <1>;
> +				hwcap-bit-nr = <58>;
> +			};
> +
> +			control-register {
> +				isa = <0>;
> +				usable-privilege = <7>;
> +			};
> +
> +			system-call-vectored {
> +				isa = <2070>;
> +				usable-privilege = <7>;
> +				os-support = <1>;
> +				fscr-bit-nr = <12>;
> +				hwcap-bit-nr = <52>;
>  			};
>  		};
>  
> @@ -138,7 +179,18 @@ UART0: serial@2000 {
>  			interrupts = <0x10 0x1>;
>  		};
>  
> -		ethernet@8020000 {
> +		gpio: gpio@7000 {
> +			device_type = "gpio";
> +			compatible = "faraday,ftgpio010";
> +			gpio-controller;
> +			#gpio-cells = <2>;
> +			reg = <0x7000 0x80>;
> +			interrupts = <0x14 1>;
> +			interrupt-controller;
> +			#interrupt-cells = <2>;
> +		};
> +
> +		enet0: ethernet@8020000 {
>  			compatible = "litex,liteeth";
>  			reg = <0x8021000 0x100
>  				0x8020800 0x100
> @@ -160,7 +212,6 @@ mmc@8040000 {
>  			reg-names = "phy", "core", "reader", "writer", "irq";
>  			bus-width = <4>;
>  			interrupts = <0x13 1>;
> -			cap-sd-highspeed;
>  			clocks = <&sys_clk>;
>  		};
>  	};



  reply	other threads:[~2025-01-29  6:36 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-28 22:49 [PATCH 0/5] Microwatt updates Paul Mackerras
2025-01-28 22:51 ` [PATCH 1/5] powerpc/microwatt: Select COMMON_CLK in order to get the clock framework Paul Mackerras
2025-01-29  5:57   ` Nicholas Piggin
2025-01-28 22:52 ` [PATCH 2/5] powerpc/microwatt: Device-tree updates Paul Mackerras
2025-01-29  6:36   ` Nicholas Piggin [this message]
2025-01-29  7:18     ` Paul Mackerras
2025-01-29  8:20       ` Nicholas Piggin
2025-01-31 17:03         ` Segher Boessenkool
2025-01-31 16:55       ` Segher Boessenkool
2025-01-31 16:53     ` Segher Boessenkool
2025-01-31 16:48   ` Segher Boessenkool
2025-01-28 22:52 ` [PATCH 3/5] powerpc/microwatt: Define an idle power-save function Paul Mackerras
2025-01-29  6:06   ` Nicholas Piggin
2025-01-29  6:49     ` Paul Mackerras
2025-01-31 16:32     ` Segher Boessenkool
2025-02-01  1:41       ` Paul Mackerras
2025-01-31 16:25   ` Segher Boessenkool
2025-01-28 22:53 ` [PATCH 4/5] powerpc: Define config option for processors without broadcast TLBIE Paul Mackerras
2025-01-29  6:14   ` Nicholas Piggin
2025-01-29  7:10     ` Paul Mackerras
2025-01-29  8:17       ` Nicholas Piggin
2025-01-31 17:30       ` Segher Boessenkool
2025-01-31 17:26   ` Segher Boessenkool
2025-01-28 22:55 ` [PATCH 5/5] powerpc/microwatt: Add SMP support Paul Mackerras
2025-01-29  6:21   ` Nicholas Piggin
2025-01-29  6:57     ` Paul Mackerras
2025-01-29  8:12       ` Nicholas Piggin
2025-01-31  1:27         ` Paul Mackerras
2025-01-29 12:50       ` Michael Ellerman
2025-01-31  1:34         ` Paul Mackerras
2025-01-31 16:13 ` [PATCH 0/5] Microwatt updates Segher Boessenkool
2025-02-01  1:22   ` Paul Mackerras
2025-03-02 10:13     ` Gabriel Paubert

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=D7ECKPNWAU7O.39PRDJ4PIG0P9@gmail.com \
    --to=npiggin@gmail.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=paulus@ozlabs.org \
    /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;
as well as URLs for NNTP newsgroup(s).