[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 12/37] hw/ppc/spapr: Encode the SCSI channel (bus) in
From: |
David Gibson |
Subject: |
[Qemu-devel] [PULL 12/37] hw/ppc/spapr: Encode the SCSI channel (bus) in the SRP LUNs |
Date: |
Mon, 4 Feb 2019 20:00:59 +1100 |
From: Thomas Huth <address@hidden>
In hw/scsi/spapr_vio.c we declare that the controller supports multiple
buses by specifying "max_channel = 7" there. So in the code that fixes
up the device tree nodes, we must encode the channel number (a.k.a. bus
number in the "Logical unit addressing format" table of SAM5) into the
64-bit LUN, too.
Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1663160
Signed-off-by: Thomas Huth <address@hidden>
Signed-off-by: David Gibson <address@hidden>
---
hw/ppc/spapr.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index 0942f35bf8..71fe552c83 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -2959,10 +2959,11 @@ static char *spapr_get_fw_dev_path(FWPathProvider *p,
BusState *bus,
if (spapr) {
/*
* Replace "address@hidden/address@hidden,0" with "address@hidden":
- * We use SRP luns of the form 8000 | (bus << 8) | (id << 5) | lun
- * in the top 16 bits of the 64-bit LUN
+ * In the top 16 bits of the 64-bit LUN, we use SRP luns of the
form
+ * 0x8000 | (target << 8) | (bus << 5) | lun
+ * (see the "Logical unit addressing format" table in SAM5)
*/
- unsigned id = 0x8000 | (d->id << 8) | d->lun;
+ unsigned id = 0x8000 | (d->id << 8) | (d->channel << 5) | d->lun;
return g_strdup_printf("address@hidden"PRIX64, qdev_fw_name(dev),
(uint64_t)id << 48);
} else if (virtio) {
--
2.20.1
- [Qemu-devel] [PULL 09/37] target/ppc/kvm: Drop useless include directive, (continued)
- [Qemu-devel] [PULL 09/37] target/ppc/kvm: Drop useless include directive, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 10/37] ppc440: Avoid reporting error when reading non-existent RAM slot, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 02/37] smbus: Add a helper to generate SPD EEPROM data, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 27/37] target/ppc: rework vmrg{l, h}{b, h, w} instructions to use Vsr* macros, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 11/37] spapr/vio: remove the "irq" property", David Gibson, 2019/02/04
- [Qemu-devel] [PULL 08/37] ppc/xive: fix remaining XiveFabric names, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 13/37] spapr: Forbid setting ic-mode for old machine types, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 05/37] ppc4xx: Rename ppc4xx_sdram_t in ppc440_uc.c to ppc440_sdram_t, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 19/37] ppc: remove the interrupt presenters from under PowerPCCPU, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 18/37] target/ppc: implement complete set of Vsr* macros, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 12/37] hw/ppc/spapr: Encode the SCSI channel (bus) in the SRP LUNs,
David Gibson <=
- [Qemu-devel] [PULL 04/37] ppc4xx: Use ram_addr_t in ppc4xx_sdram_adjust(), David Gibson, 2019/02/04
- [Qemu-devel] [PULL 15/37] xive: add a get_tctx() method to the XiveRouter, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 17/37] spapr: move the interrupt presenters under machine_data, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 07/37] sam460ex: Fix support for memory larger than 1GB, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 28/37] target/ppc: rework vmul{e, o}{s, u}{b, h, w} instructions to use Vsr* macros, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 06/37] ppc4xx: Pass array index to function instead of pointer into the array, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 22/37] MAINTAINERS: Merge the two e500 sections, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 23/37] spapr: Drop unused parameters from fdt building helper, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 24/37] MAINTAINERS: add myself as maintainer for Mac Old World and New World machines, David Gibson, 2019/02/04
- [Qemu-devel] [PULL 25/37] QemuMacDrivers: update qemu_vga.ndrv to 90c488d built from submodule, David Gibson, 2019/02/04