[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH hurd] rumpdisk: Include complete USB stack to enable mass sto
From: |
Samuel Thibault |
Subject: |
Re: [PATCH hurd] rumpdisk: Include complete USB stack to enable mass storage driver |
Date: |
Sun, 25 Jun 2023 18:41:11 +0200 |
User-agent: |
NeoMutt/20170609 (1.8.3) |
Damien Zammit, le dim. 25 juin 2023 12:35:51 +0000, a ecrit:
> This simple change allows hurd to be bootable off usb!
Well, yes and no :)
We also need /dev entries. It happens that this re-uses /dev/sd*
names, so we need to care about compatibility. We probably want
rumpdisk_device_open to forward to the kernel when 'disabled' is true.
> It is not ideal to have entire usb stack with the mass storage driver
> and combined with SATA, but there is no easy way to separate
> the usb stack into host/device yet.
Ok, but can't we build a separate rumpusbdisk that only has the USB
drivers? Each process (SATA+IDE and USB) can easily drive its own PCI
card.
> Caveats: USB seems to share IRQs with network device,
> which does not seem to work well currently.
> I am not sure of the status of irq sharing but it seems broken.
That was supposed to be working, but evil lies in the details as usual.
> ---
> rumpdisk/Makefile | 2 +-
> rumpdisk/block-rump.c | 3 ++-
> 2 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/rumpdisk/Makefile b/rumpdisk/Makefile
> index b59aaf9a..9ee8a1d3 100644
> --- a/rumpdisk/Makefile
> +++ b/rumpdisk/Makefile
> @@ -15,7 +15,7 @@
> # along with this program; if not, write to the Free Software
> # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
>
> -RUMPLIBS=rump rumpuser rumpdev rumpdev_disk rumpdev_pci rumpvfs
> rumpdev_ahcisata rumpdev_piixide rumpdev_ata
> +RUMPLIBS=rump rumpuser rumpdev rumpdev_disk rumpdev_pci rumpvfs
> rumpdev_ahcisata rumpdev_piixide rumpdev_ata rumpdev_usb rumpdev_pci_usbhc
> rumpdev_umass
> RUMPEXTRA=rumpdev_scsipi
>
> # If we have a configured tree, include the configuration so that we
> diff --git a/rumpdisk/block-rump.c b/rumpdisk/block-rump.c
> index 5ceb14ae..0a8cbe44 100644
> --- a/rumpdisk/block-rump.c
> +++ b/rumpdisk/block-rump.c
> @@ -46,7 +46,7 @@
> #define BLKRRPART 0x125F /* re-read partition table */
>
> #define DISK_NAME_LEN 32
> -#define MAX_DISK_DEV 2
> +#define MAX_DISK_DEV 3
>
> static bool disabled;
>
> @@ -108,6 +108,7 @@ is_disk_device (const char *name)
> const char *dev;
> const char *allowed_devs[MAX_DISK_DEV] = {
> "wd",
> + "sd",
> "cd"
> };
> uint8_t i;
> --
> 2.40.1