diff options
author | Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> | 2007-01-26 19:07:51 -0800 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-02-07 14:03:17 +1100 |
commit | 6c7be7d385f4911895877e0f0697c598f600136f (patch) | |
tree | d8bffe6e30b7bffc66ffe74e636ad30a322122cd /include | |
parent | eebb81c13aa831a623e903bbae97a23fe9be93eb (diff) |
[POWERPC] ps3: repository storage support
Handle storage-related repository data:
- Add missing implementations of ps3_repository_read_stor_*() repository
accessors.
- Dump storage properties in debug mode
- Add PS3_DEV_TYPE_STOR_{DISK,ROM,FLASH} device types (which are identical to
the corresponding SCSI device types) to enum ps3_dev_type
Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com>
Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-powerpc/ps3.h | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/include/asm-powerpc/ps3.h b/include/asm-powerpc/ps3.h index b56aca28b26..8fed3a041de 100644 --- a/include/asm-powerpc/ps3.h +++ b/include/asm-powerpc/ps3.h @@ -25,6 +25,7 @@ #include <linux/init.h> #include <linux/types.h> #include <linux/device.h> +#include <scsi/scsi.h> /** * struct ps3_device_id - HV bus device identifier from the system repository @@ -255,9 +256,12 @@ enum ps3_bus_type { }; enum ps3_dev_type { + PS3_DEV_TYPE_STOR_DISK = TYPE_DISK, /* 0 */ PS3_DEV_TYPE_SB_GELIC = 3, PS3_DEV_TYPE_SB_USB = 4, + PS3_DEV_TYPE_STOR_ROM = TYPE_ROM, /* 5 */ PS3_DEV_TYPE_SB_GPIO = 6, + PS3_DEV_TYPE_STOR_FLASH = TYPE_RBC, /* 14 */ }; int ps3_repository_read_bus_str(unsigned int bus_index, const char *bus_str, @@ -327,21 +331,27 @@ int ps3_repository_find_reg(const struct ps3_repository_device *dev, /* repository block device info */ -int ps3_repository_read_dev_port(unsigned int bus_index, +int ps3_repository_read_stor_dev_port(unsigned int bus_index, unsigned int dev_index, u64 *port); -int ps3_repository_read_dev_blk_size(unsigned int bus_index, +int ps3_repository_read_stor_dev_blk_size(unsigned int bus_index, unsigned int dev_index, u64 *blk_size); -int ps3_repository_read_dev_num_blocks(unsigned int bus_index, +int ps3_repository_read_stor_dev_num_blocks(unsigned int bus_index, unsigned int dev_index, u64 *num_blocks); -int ps3_repository_read_dev_num_regions(unsigned int bus_index, +int ps3_repository_read_stor_dev_num_regions(unsigned int bus_index, unsigned int dev_index, unsigned int *num_regions); -int ps3_repository_read_dev_region_id(unsigned int bus_index, +int ps3_repository_read_stor_dev_region_id(unsigned int bus_index, unsigned int dev_index, unsigned int region_index, unsigned int *region_id); -int ps3_repository_read_dev_region_size(unsigned int bus_index, +int ps3_repository_read_stor_dev_region_size(unsigned int bus_index, unsigned int dev_index, unsigned int region_index, u64 *region_size); -int ps3_repository_read_dev_region_start(unsigned int bus_index, +int ps3_repository_read_stor_dev_region_start(unsigned int bus_index, unsigned int dev_index, unsigned int region_index, u64 *region_start); +int ps3_repository_read_stor_dev_info(unsigned int bus_index, + unsigned int dev_index, u64 *port, u64 *blk_size, + u64 *num_blocks, unsigned int *num_regions); +int ps3_repository_read_stor_dev_region(unsigned int bus_index, + unsigned int dev_index, unsigned int region_index, + unsigned int *region_id, u64 *region_start, u64 *region_size); /* repository pu and memory info */ |