Merge git://git.denx.de/u-boot-dm
[platform/kernel/u-boot.git] / drivers / usb / emul / sandbox_flash.c
index 9abb323..98d20c0 100644 (file)
@@ -244,7 +244,7 @@ static int handle_ufi_command(struct sandbox_flash_plat *plat,
                              struct sandbox_flash_priv *priv, const void *buff,
                              int len)
 {
-       const struct SCSI_cmd_block *req = buff;
+       const struct scsi_cmd *req = buff;
 
        switch (*req->cmd) {
        case SCSI_INQUIRY: {
@@ -371,10 +371,8 @@ err:
 static int sandbox_flash_ofdata_to_platdata(struct udevice *dev)
 {
        struct sandbox_flash_plat *plat = dev_get_platdata(dev);
-       const void *blob = gd->fdt_blob;
 
-       plat->pathname = fdt_getprop(blob, dev_of_offset(dev),
-                                    "sandbox,filepath", NULL);
+       plat->pathname = dev_read_string(dev, "sandbox,filepath");
 
        return 0;
 }