summaryrefslogtreecommitdiff
path: root/drivers/firewire
diff options
context:
space:
mode:
authorStefan Richter <stefanr@s5r6.in-berlin.de>2009-09-06 18:49:48 +0200
committerStefan Richter <stefanr@s5r6.in-berlin.de>2009-09-12 14:48:40 +0200
commit18668ff9a3232d5f942a2f7abc1ad67d2760dcdf (patch)
tree251594c51144f5993b0975c5fb4ba9f200e5c79f /drivers/firewire
parent928ec5f148e729076e9202e7c78babede628a50c (diff)
downloadlinux-riscv-18668ff9a3232d5f942a2f7abc1ad67d2760dcdf.tar.gz
linux-riscv-18668ff9a3232d5f942a2f7abc1ad67d2760dcdf.tar.bz2
linux-riscv-18668ff9a3232d5f942a2f7abc1ad67d2760dcdf.zip
firewire: core: header file cleanup
fw_card_get, fw_card_put, fw_card_release are currently not exported for use outside the firewire-core. Move their definitions/ declarations from the subsystem header file to the core header file. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/firewire')
-rw-r--r--drivers/firewire/core.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/firewire/core.h b/drivers/firewire/core.h
index 6052816be353..7ff6e7585152 100644
--- a/drivers/firewire/core.h
+++ b/drivers/firewire/core.h
@@ -96,6 +96,20 @@ int fw_core_initiate_bus_reset(struct fw_card *card, int short_reset);
int fw_compute_block_crc(u32 *block);
void fw_schedule_bm_work(struct fw_card *card, unsigned long delay);
+static inline struct fw_card *fw_card_get(struct fw_card *card)
+{
+ kref_get(&card->kref);
+
+ return card;
+}
+
+void fw_card_release(struct kref *kref);
+
+static inline void fw_card_put(struct fw_card *card)
+{
+ kref_put(&card->kref, fw_card_release);
+}
+
/* -cdev */