summaryrefslogtreecommitdiffstats
path: root/arch/sandbox
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2024-03-04 19:59:08 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2024-03-05 16:28:05 +0100
commit46ba653ef10e66340f68d4bba4d631f754702064 (patch)
tree3937d8919c59cc545547c3d46e6959640a6d8928 /arch/sandbox
parentaca95e86e163d1c3b981d1aba51208ed42bb332b (diff)
downloadbarebox-46ba653ef10e66340f68d4bba4d631f754702064.tar.gz
barebox-46ba653ef10e66340f68d4bba4d631f754702064.tar.xz
block: record block device type
Software running under EFI can query the type of a block device. For barebox to be able to report this, start assigning types to all block devices it can create. No functional change yet. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20240304190038.3486881-24-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/sandbox')
-rw-r--r--arch/sandbox/board/hostfile.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/sandbox/board/hostfile.c b/arch/sandbox/board/hostfile.c
index 88d4d6605f..7afad95b6d 100644
--- a/arch/sandbox/board/hostfile.c
+++ b/arch/sandbox/board/hostfile.c
@@ -161,6 +161,7 @@ static int hf_probe(struct device *dev)
priv->blk.ops = &hf_blk_ops;
priv->blk.blockbits = SECTOR_SHIFT;
priv->blk.num_blocks = reg[1] / SECTOR_SIZE;
+ priv->blk.type = BLK_TYPE_VIRTUAL;
err = blockdevice_register(&priv->blk);
if (err)