X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-ppc%2Fpmac_feature.h;h=4945a50ce07567bac6ba2587955cd31098b1ddc6;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=ee15e9c59aa2e866bafe342755e0b82f84acea09;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/include/asm-ppc/pmac_feature.h b/include/asm-ppc/pmac_feature.h index ee15e9c59..4945a50ce 100644 --- a/include/asm-ppc/pmac_feature.h +++ b/include/asm-ppc/pmac_feature.h @@ -9,7 +9,7 @@ * Ben. Herrenschmidt. * * - * Note: I removed media-bay details from the feature stuff, I beleive it's + * Note: I removed media-bay details from the feature stuff, I believe it's * not worth it, the media-bay driver can directly use the mac-io * ASIC registers. * @@ -125,6 +125,7 @@ #define PMAC_MB_HAS_FW_POWER 0x00000002 #define PMAC_MB_OLD_CORE99 0x00000004 #define PMAC_MB_MOBILE 0x00000008 +#define PMAC_MB_MAY_SLEEP 0x00000010 /* * Feature calls supported on pmac @@ -238,7 +239,10 @@ static inline long pmac_call_feature(int selector, struct device_node* node, /* PMAC_FTR_SLEEP_STATE (struct device_node* node, 0, int value) * set the sleep state of the motherboard. + * * Pass -1 as value to query for sleep capability + * Pass 1 to set IOs to sleep + * Pass 0 to set IOs to wake */ #define PMAC_FTR_SLEEP_STATE PMAC_FTR_DEF(15) @@ -279,11 +283,22 @@ static inline long pmac_call_feature(int selector, struct device_node* node, */ #define PMAC_FTR_AACK_DELAY_ENABLE PMAC_FTR_DEF(20) +/* PMAC_FTR_DEVICE_CAN_WAKE + * + * Used by video drivers to inform system that they can actually perform + * wakeup from sleep + */ +#define PMAC_FTR_DEVICE_CAN_WAKE PMAC_FTR_DEF(22) + /* Don't use those directly, they are for the sake of pmac_setup.c */ extern long pmac_do_feature_call(unsigned int selector, ...); extern void pmac_feature_init(void); +/* Video suspend tweak */ +extern void pmac_set_early_video_resume(void (*proc)(void *data), void *data); +extern void pmac_call_early_video_resume(void); + #define PMAC_FTR_DEF(x) ((_MACH_Pmac << 16) | (x)) @@ -315,7 +330,7 @@ struct macio_chip int type; const char *name; int rev; - volatile u32 *base; + volatile u32 __iomem *base; unsigned long flags; /* For use by macio_asic PCI driver */ @@ -333,7 +348,7 @@ extern struct macio_chip macio_chips[MAX_MACIO_CHIPS]; extern struct macio_chip* macio_find(struct device_node* child, int type); #define MACIO_FCR32(macio, r) ((macio)->base + ((r) >> 2)) -#define MACIO_FCR8(macio, r) (((volatile u8*)((macio)->base)) + (r)) +#define MACIO_FCR8(macio, r) (((volatile u8 __iomem *)((macio)->base)) + (r)) #define MACIO_IN32(r) (in_le32(MACIO_FCR32(macio,r))) #define MACIO_OUT32(r,v) (out_le32(MACIO_FCR32(macio,r), (v)))