aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Ott <sebott@linux.vnet.ibm.com>2013-01-28 13:34:26 -0500
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2013-02-14 09:55:09 -0500
commit58fece7827a7cc40e02bc68a7db8229166984893 (patch)
tree7305835124de7f16cd9d9dbe8e4c8ca65af69696
parent88e7616e407fd60ad96e71349393397cf72f8b8d (diff)
s390/scm: use inline dummy functions
Convert the defines for the !CONFIG_SCM* stuff to static inline functions. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
-rw-r--r--drivers/s390/block/scm_blk.h41
-rw-r--r--drivers/s390/cio/chsc.h2
2 files changed, 29 insertions, 14 deletions
diff --git a/drivers/s390/block/scm_blk.h b/drivers/s390/block/scm_blk.h
index 7ac6bad919ef..3c1ccf494647 100644
--- a/drivers/s390/block/scm_blk.h
+++ b/drivers/s390/block/scm_blk.h
@@ -68,19 +68,34 @@ void scm_initiate_cluster_request(struct scm_request *);
68void scm_cluster_request_irq(struct scm_request *); 68void scm_cluster_request_irq(struct scm_request *);
69bool scm_test_cluster_request(struct scm_request *); 69bool scm_test_cluster_request(struct scm_request *);
70bool scm_cluster_size_valid(void); 70bool scm_cluster_size_valid(void);
71#else 71#else /* CONFIG_SCM_BLOCK_CLUSTER_WRITE */
72#define __scm_free_rq_cluster(scmrq) {} 72static inline void __scm_free_rq_cluster(struct scm_request *scmrq) {}
73#define __scm_alloc_rq_cluster(scmrq) 0 73static inline int __scm_alloc_rq_cluster(struct scm_request *scmrq)
74#define scm_request_cluster_init(scmrq) {} 74{
75#define scm_reserve_cluster(scmrq) true 75 return 0;
76#define scm_release_cluster(scmrq) {} 76}
77#define scm_blk_dev_cluster_setup(bdev) {} 77static inline void scm_request_cluster_init(struct scm_request *scmrq) {}
78#define scm_need_cluster_request(scmrq) false 78static inline bool scm_reserve_cluster(struct scm_request *scmrq)
79#define scm_initiate_cluster_request(scmrq) {} 79{
80#define scm_cluster_request_irq(scmrq) {} 80 return true;
81#define scm_test_cluster_request(scmrq) false 81}
82#define scm_cluster_size_valid() true 82static inline void scm_release_cluster(struct scm_request *scmrq) {}
83#endif 83static inline void scm_blk_dev_cluster_setup(struct scm_blk_dev *bdev) {}
84static inline bool scm_need_cluster_request(struct scm_request *scmrq)
85{
86 return false;
87}
88static inline void scm_initiate_cluster_request(struct scm_request *scmrq) {}
89static inline void scm_cluster_request_irq(struct scm_request *scmrq) {}
90static inline bool scm_test_cluster_request(struct scm_request *scmrq)
91{
92 return false;
93}
94static inline bool scm_cluster_size_valid(void)
95{
96 return true;
97}
98#endif /* CONFIG_SCM_BLOCK_CLUSTER_WRITE */
84 99
85extern debug_info_t *scm_debug; 100extern debug_info_t *scm_debug;
86 101
diff --git a/drivers/s390/cio/chsc.h b/drivers/s390/cio/chsc.h
index 662dab4b93e6..227e05f674b3 100644
--- a/drivers/s390/cio/chsc.h
+++ b/drivers/s390/cio/chsc.h
@@ -157,7 +157,7 @@ int chsc_scm_info(struct chsc_scm_info *scm_area, u64 token);
157#ifdef CONFIG_SCM_BUS 157#ifdef CONFIG_SCM_BUS
158int scm_update_information(void); 158int scm_update_information(void);
159#else /* CONFIG_SCM_BUS */ 159#else /* CONFIG_SCM_BUS */
160#define scm_update_information() 0 160static inline int scm_update_information(void) { return 0; }
161#endif /* CONFIG_SCM_BUS */ 161#endif /* CONFIG_SCM_BUS */
162 162
163 163