Michal Simek | c886f35 | 2016-09-08 15:06:45 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2015 Google, Inc |
| 3 | * Written by Simon Glass <sjg@chromium.org> |
| 4 | * Copyright (c) 2016 Xilinx, Inc |
| 5 | * Written by Michal Simek |
| 6 | * |
| 7 | * Based on ahci-uclass.c |
| 8 | * |
| 9 | * SPDX-License-Identifier: GPL-2.0+ |
| 10 | */ |
| 11 | |
| 12 | #include <common.h> |
| 13 | #include <dm.h> |
| 14 | #include <scsi.h> |
| 15 | |
| 16 | static int scsi_post_probe(struct udevice *dev) |
| 17 | { |
| 18 | debug("%s: device %p\n", __func__, dev); |
| 19 | scsi_low_level_init(0, dev); |
| 20 | return 0; |
| 21 | } |
| 22 | |
| 23 | UCLASS_DRIVER(scsi) = { |
| 24 | .id = UCLASS_SCSI, |
| 25 | .name = "scsi", |
| 26 | .post_probe = scsi_post_probe, |
Simon Glass | b08fbff | 2017-06-14 21:28:31 -0600 | [diff] [blame^] | 27 | .per_device_platdata_auto_alloc_size = sizeof(struct scsi_platdata), |
Michal Simek | c886f35 | 2016-09-08 15:06:45 +0200 | [diff] [blame] | 28 | }; |