PING Hi all, could you have a look at this small patch? See also: https://patchew.org/QEMU/20240330203520.64892-1-giacomo.parmeggi...@gmail.com/
BR, Giacomo Parmeggiani On Sat, Mar 30, 2024 at 9:36 PM Giacomo Parmeggiani < giacomo.parmeggi...@gmail.com> wrote: > This introduces the GigaDevice GD25WQ32E flash, including the SFDP table > > Signed-off-by: Giacomo Parmeggiani <giacomo.parmeggi...@gmail.com> > --- > hw/block/m25p80.c | 2 ++ > hw/block/m25p80_sfdp.c | 40 ++++++++++++++++++++++++++++++++++++++++ > hw/block/m25p80_sfdp.h | 2 ++ > 3 files changed, 44 insertions(+) > > diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c > index 8dec134832..6cc05b63e5 100644 > --- a/hw/block/m25p80.c > +++ b/hw/block/m25p80.c > @@ -205,6 +205,8 @@ static const FlashPartInfo known_devices[] = { > /* GigaDevice */ > { INFO("gd25q32", 0xc84016, 0, 64 << 10, 64, ER_4K) }, > { INFO("gd25q64", 0xc84017, 0, 64 << 10, 128, ER_4K) }, > + { INFO("gd25wq32e", 0xc86516, 0, 64 << 10, 64, ER_4K), > + .sfdp_read = m25p80_sfdp_gd25wq32e }, > > /* Intel/Numonyx -- xxxs33b */ > { INFO("160s33b", 0x898911, 0, 64 << 10, 32, 0) }, > diff --git a/hw/block/m25p80_sfdp.c b/hw/block/m25p80_sfdp.c > index 6ee2cfaf11..cb0963328d 100644 > --- a/hw/block/m25p80_sfdp.c > +++ b/hw/block/m25p80_sfdp.c > @@ -406,3 +406,43 @@ static const uint8_t sfdp_is25wp256[] = { > 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > }; > define_sfdp_read(is25wp256); > + > +/* > + * GigaDevice > + */ > + > +static const uint8_t sfdp_gd25wq32e[] = { > + 0x53, 0x46, 0x44, 0x50, 0x06, 0x01, 0x01, 0xff, > + 0x00, 0x06, 0x01, 0x10, 0x30, 0x00, 0x00, 0xff, > + 0xc8, 0x00, 0x01, 0x03, 0x90, 0x00, 0x00, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xe5, 0x20, 0xf1, 0xff, 0xff, 0xff, 0xff, 0x01, > + 0x44, 0xeb, 0x08, 0x6b, 0x08, 0x3b, 0x42, 0xbb, > + 0xee, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, > + 0xff, 0xff, 0x00, 0xff, 0x0c, 0x20, 0x0f, 0x52, > + 0x10, 0xd8, 0x00, 0xff, 0x63, 0x92, 0xfd, 0xfe, > + 0x83, 0x2f, 0x26, 0x46, 0xec, 0x82, 0x18, 0x44, > + 0x7a, 0x75, 0x7a, 0x75, 0x04, 0xbd, 0xd5, 0x5c, > + 0x00, 0x06, 0x64, 0x00, 0x08, 0x10, 0x00, 0x00, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0x00, 0x36, 0x50, 0x16, 0x9e, 0xf9, 0x77, 0x64, > + 0xfc, 0xcb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, > + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff > +}; > +define_sfdp_read(gd25wq32e); > diff --git a/hw/block/m25p80_sfdp.h b/hw/block/m25p80_sfdp.h > index 1733b56950..7d1f60f2ee 100644 > --- a/hw/block/m25p80_sfdp.h > +++ b/hw/block/m25p80_sfdp.h > @@ -29,4 +29,6 @@ uint8_t m25p80_sfdp_w25q01jvq(uint32_t addr); > > uint8_t m25p80_sfdp_is25wp256(uint32_t addr); > > +uint8_t m25p80_sfdp_gd25wq32e(uint32_t addr); > + > #endif > -- > 2.32.1 (Apple Git-133) > > -- *Giacomo Parmeggiani*