arm64: dts: Add a virtio disk to the RTSM motherboard
PATCH 1/2 arm64: dts: Add a virtio disk to the RTSM motherboard
From: Mark Hambleton <[email protected]>
Describe the virtio device so we can mount disk images in the simulator.
[Reduced the size of the region based on feedback from review -- broonie]
--- arch/arm64/boot/dts/rtsm_ve-motherboard.dtsi | 6 ++++++ 1 file changed, 6 insertions(+)
arch/arm64/boot/dts/rtsm_ve-motherboard.dtsi +6 -0
@@ -183,6 +183,12 @@ clocks = <&v2m_oscclk1>, <&v2m_clk24mhz>; clock-names = "clcdclk", "apb_pclk"; }; + + virtio_block at 0130000 { + compatible = "virtio,mmio"; + reg = <0x130000 0x200>; + interrupts = <42>; + }; }; v2m_fixed_3v3: fixedregulator at 0 {
Signature · 1 line
1.8.5.2
PATCH 2/2 arm64: dts: Reduce size of virtio block device for foundation model
From: Mark Brown <[email protected]>
Will Deacon observed that kvmtool uses a size of 0x200 for virtio block memory region and that the virtio block spec only uses 31 bytes in the device specific region at 0x100 so reduce the region to a less wasteful 0x200.
--- arch/arm64/boot/dts/foundation-v8.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/foundation-v8.dts +1 -1
@@ -224,7 +224,7 @@ virtio_block at 0130000 { compatible = "virtio,mmio"; - reg = <0x130000 0x1000>; + reg = <0x130000 0x200>; interrupts = <42>; }; };
Signature · 1 line
1.8.5.2
PATCH 2/2 arm64: dts: Reduce size of virtio block device for foundation model
Quoted 6 lines · Mark Brown
From: Mark Brown <[email protected]>
Will Deacon observed that kvmtool uses a size of
0x200for virtio block memory region and that the virtio block spec only uses 31 bytes in the device specific region at0x100so reduce the region to a less wasteful0x200.
What do we waste by keeping it at 4K? That's ioremap'ed, so we use a full page anyway.
Signature · 1 line
Catalin
PATCH 2/2 arm64: dts: Reduce size of virtio block device for foundation model
Quoted 10 lines · Catalin Marinas
Quoted 6 lines · Mark Brown
From: Mark Brown <[email protected]>
Will Deacon observed that kvmtool uses a size of
0x200for virtio block memory region and that the virtio block spec only uses 31 bytes in the device specific region at0x100so reduce the region to a less wasteful0x200.What do we waste by keeping it at 4K? That's ioremap'ed, so we use a full page anyway.
This was done for consistency with the same change made in RTSM
motherboard patch so that we register the same device in the same way.
That change was at Will's request, he did point out that we might use
16K pages in some systems IIRC but personally I'm not sure it makes a
huge difference either way - I do think we should keep all registrations
of the device consistent though to avoid user confusion about how to use
it.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131220/656f6dec/attachment.sig>
PATCH 2/2 arm64: dts: Reduce size of virtio block device for foundation model
Quoted 12 lines · Mark Brown
Quoted 10 lines · Catalin Marinas
Quoted 6 lines · Mark Brown
From: Mark Brown <[email protected]>
Will Deacon observed that kvmtool uses a size of
0x200for virtio block memory region and that the virtio block spec only uses 31 bytes in the device specific region at0x100so reduce the region to a less wasteful0x200.What do we waste by keeping it at 4K? That's ioremap'ed, so we use a full page anyway.
Quoted 7 lines
This was done for consistency with the same change made in RTSM motherboard patch so that we register the same device in the same way. That change was at Will's request, he did point out that we might use 16K pages in some systems IIRC but personally I'm not sure it makes a huge difference either way - I do think we should keep all registrations of the device consistent though to avoid user confusion about how to use it.
OK. Applied.
Signature · 1 line
Catalin