summaryrefslogtreecommitdiffstats
path: root/include/ata_drive.h
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2013-06-19 23:25:07 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2013-06-21 07:40:36 +0200
commita6d4345e1b594c3abbfcc6d004e41d539be6169f (patch)
tree10b3f151448239b1fd2cdf58641a2469137866c6 /include/ata_drive.h
parent466feef31e1fe7e98652be13a8ea3dc2171e3034 (diff)
downloadbarebox-a6d4345e1b594c3abbfcc6d004e41d539be6169f.tar.gz
barebox-a6d4345e1b594c3abbfcc6d004e41d539be6169f.tar.xz
ata: ide: embed ata_ioports into struct ide_port and export it
Embedding struct ata_ioports into struct ide_port saves us an allocation. Making it available to client drivers is necessary to give them access to struct ata_port which is needed in the next patch. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/ata_drive.h')
-rw-r--r--include/ata_drive.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/ata_drive.h b/include/ata_drive.h
index 818247a181..6d6cca43bf 100644
--- a/include/ata_drive.h
+++ b/include/ata_drive.h
@@ -143,7 +143,12 @@ struct ata_port {
int probe;
};
-int ide_port_register(struct device_d *, struct ata_ioports *, const char *);
+struct ide_port {
+ struct ata_ioports io; /**< register file */
+ struct ata_port port;
+};
+
+int ide_port_register(struct ide_port *ide);
int ata_port_register(struct ata_port *port);
int ata_port_detect(struct ata_port *port);