diff options
author | imp <imp@FreeBSD.org> | 2009-02-06 07:49:03 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2009-02-06 07:49:03 +0000 |
commit | 8448edb36a795b0b0f079d17e7748e4f621d761a (patch) | |
tree | 88f9369bbb1881dc6201c6d448f9320d4f1fdbce /sys/dev/pccard | |
parent | 0c3d4be2e1b46f6564cf58a665e35dc19bd88806 (diff) | |
download | FreeBSD-src-8448edb36a795b0b0f079d17e7748e4f621d761a.zip FreeBSD-src-8448edb36a795b0b0f079d17e7748e4f621d761a.tar.gz |
Store the entire funce for disk type functions (eg CF cards and the
like).
Diffstat (limited to 'sys/dev/pccard')
-rw-r--r-- | sys/dev/pccard/pccard_cis.c | 2 | ||||
-rw-r--r-- | sys/dev/pccard/pccardvarp.h | 19 |
2 files changed, 20 insertions, 1 deletions
diff --git a/sys/dev/pccard/pccard_cis.c b/sys/dev/pccard/pccard_cis.c index 62313cc..605ea17 100644 --- a/sys/dev/pccard/pccard_cis.c +++ b/sys/dev/pccard/pccard_cis.c @@ -1283,6 +1283,8 @@ decode_funce(const struct pccard_tuple *tuple, struct pccard_function *pf) if (type == PCCARD_TPLFE_TYPE_DISK_DEVICE_INTERFACE) { pf->pf_funce_disk_interface = pccard_tuple_read_1(tuple, 1); + pf->pf_funce_disk_power + = pccard_tuple_read_1(tuple, 2); } break; case PCCARD_FUNCTION_NETWORK: diff --git a/sys/dev/pccard/pccardvarp.h b/sys/dev/pccard/pccardvarp.h index e418730..576238b 100644 --- a/sys/dev/pccard/pccardvarp.h +++ b/sys/dev/pccard/pccardvarp.h @@ -75,7 +75,23 @@ struct pccard_config_entry { }; struct pccard_funce_disk { - int pfd_interface; + uint8_t pfd_interface; +#define PFD_I_V_MASK 0x3 +#define PFD_I_V_NONE_REQUIRED 0x0 +#define PFD_I_V_REQ_MOD_ACC 0x1 +#define PFD_I_V_REQ_ACC 0x2 +#define PFD_I_V_REQ_ALWYS 0x1 +#define PFD_I_S 0x4 /* 0 rotating, 1 silicon */ +#define PFD_I_U 0x8 /* SN Uniq? */ +#define PFD_I_D 0x10 /* 0 - 1 drive, 1 - 2 drives */ + uint8_t pfd_power; +#define PFD_P_P0 0x1 +#define PFD_P_P1 0x2 +#define PFD_P_P2 0x4 +#define PFD_P_P3 0x8 +#define PFD_P_N 0x10 /* 3f7/377 excluded? */ +#define PFD_P_E 0x20 /* Index bit supported? */ +#define PFD_P_I 0x40 /* twincard */ }; struct pccard_funce_lan { @@ -119,6 +135,7 @@ struct pccard_function { union pccard_funce pf_funce; /* CISTPL_FUNCE */ #define pf_funce_disk_interface pf_funce.pfv_disk.pfd_interface +#define pf_funce_disk_power pf_funce.pfv_disk.pfd_power #define pf_funce_lan_nid pf_funce.pfv_lan.pfl_nid #define pf_funce_lan_nidlen pf_funce.pfv_lan.pfl_nidlen }; |