ckrm_E15-io-controller
[linux-2.6.git] / include / linux / ckrm_rc.h
index f403167..b46cfd9 100644 (file)
@@ -223,17 +223,7 @@ typedef struct ckrm_core_class {
  * OTHER
  ******************************************************************************/
 
-#define ckrm_get_res_class(rescls, resid, type) \
-       ((type*) (((resid != -1) && ((rescls) != NULL) \
-                          && ((rescls) != (void *)-1)) ? \
-        ((struct ckrm_core_class *)(rescls))->res_class[resid] : NULL))
-
-#define ckrm_set_res_class(rescls, resid, value) \
-do { \
-       if ((resid != -1) && ((rescls) != NULL)) { \
-        ((struct ckrm_core_class *)(rescls))->res_class[resid] = value; \
-       } \
-} while (0)
+#define ckrm_get_res_class(rescls,resid,type)   ((type*)((rescls)->res_class[resid]))
 
 extern int ckrm_register_res_ctlr(struct ckrm_classtype *, ckrm_res_ctlr_t *);
 extern int ckrm_unregister_res_ctlr(ckrm_res_ctlr_t *);