[RFC PATCH 4/4] hw/hppa/dino: Do not accept accesses to registers 0x818 and 0x82c

Philippe Mathieu-Daudé posted 4 patches 5 years, 12 months ago
There is a newer version of this series
[RFC PATCH 4/4] hw/hppa/dino: Do not accept accesses to registers 0x818 and 0x82c
Posted by Philippe Mathieu-Daudé 5 years, 12 months ago
Register 0x818 is documented as 'undefined', and register
0x82c is not documented. Refuse their access.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 hw/hppa/dino.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/hw/hppa/dino.c b/hw/hppa/dino.c
index be799aad43..2b1b38c58a 100644
--- a/hw/hppa/dino.c
+++ b/hw/hppa/dino.c
@@ -181,7 +181,9 @@ static bool dino_chip_mem_valid(void *opaque, hwaddr addr,
     case DINO_IO_ADDR_EN:
     case DINO_PCI_IO_DATA:
     case DINO_TOC_ADDR:
-    case DINO_GMASK ... DINO_TLTIM:
+    case DINO_GMASK ... DINO_PCISTS:
+    case DINO_MLTIM ... DINO_PCIWOR:
+    case DINO_TLTIM:
         ret = true;
         break;
     case DINO_PCI_IO_DATA + 2:
-- 
2.21.1


Re: [RFC PATCH 4/4] hw/hppa/dino: Do not accept accesses to registers 0x818 and 0x82c
Posted by Helge Deller 5 years, 11 months ago
On 14.02.20 00:41, Philippe Mathieu-Daudé wrote:
> Register 0x818 is documented as 'undefined', and register
> 0x82c is not documented. Refuse their access.
>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Acked-by: Helge Deller <deller@gmx.de>



> ---
>  hw/hppa/dino.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/hw/hppa/dino.c b/hw/hppa/dino.c
> index be799aad43..2b1b38c58a 100644
> --- a/hw/hppa/dino.c
> +++ b/hw/hppa/dino.c
> @@ -181,7 +181,9 @@ static bool dino_chip_mem_valid(void *opaque, hwaddr addr,
>      case DINO_IO_ADDR_EN:
>      case DINO_PCI_IO_DATA:
>      case DINO_TOC_ADDR:
> -    case DINO_GMASK ... DINO_TLTIM:
> +    case DINO_GMASK ... DINO_PCISTS:
> +    case DINO_MLTIM ... DINO_PCIWOR:
> +    case DINO_TLTIM:
>          ret = true;
>          break;
>      case DINO_PCI_IO_DATA + 2:
>