mtd: nand: fix ONFI parameter page layout
authorBoris BREZILLON <boris.brezillon@free-electrons.com>
Mon, 23 Nov 2015 10:23:07 +0000 (11:23 +0100)
committerBrian Norris <computersforpeace@gmail.com>
Tue, 1 Dec 2015 19:03:42 +0000 (11:03 -0800)
src_ssync_features field is only 1 byte large, and the 4th reserved area
is actually 8 bytes large.

Fixes: d1e1f4e42b5 ("mtd: nand: add support for reading ONFI parameters from NAND device")
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
include/linux/mtd/nand.h

index 056d1650eb89f2e84751c5a3631e55876fabd53c..eaf48b5a95dd16ec58a368fed7af098e1def5e6a 100644 (file)
@@ -276,7 +276,7 @@ struct nand_onfi_params {
        __le16 t_r;
        __le16 t_ccs;
        __le16 src_sync_timing_mode;
-       __le16 src_ssync_features;
+       u8 src_ssync_features;
        __le16 clk_pin_capacitance_typ;
        __le16 io_pin_capacitance_typ;
        __le16 input_pin_capacitance_typ;
@@ -284,7 +284,7 @@ struct nand_onfi_params {
        u8 driver_strength_support;
        __le16 t_int_r;
        __le16 t_ald;
-       u8 reserved4[7];
+       u8 reserved4[8];
 
        /* vendor */
        __le16 vendor_revision;