diff options
author | simokawa <simokawa@FreeBSD.org> | 2003-10-02 04:06:56 +0000 |
---|---|---|
committer | simokawa <simokawa@FreeBSD.org> | 2003-10-02 04:06:56 +0000 |
commit | db5d831317931b7bb1d2ea7b34c895d5de9e931e (patch) | |
tree | 7f27d60f89b5c06e7ea329138d86ab46f08532d4 /sys/dev/firewire/firewire.h | |
parent | 1c522512fd8b855dc3d6dbd26fed59bda6e9f0e4 (diff) | |
download | FreeBSD-src-db5d831317931b7bb1d2ea7b34c895d5de9e931e.zip FreeBSD-src-db5d831317931b7bb1d2ea7b34c895d5de9e931e.tar.gz |
MFp4: Change struct fw_xfer to reduce memory copy in fwmem_*() functions.
And many changes.
* all
- Major change of struct fw_xfer.
o {send,recv}.buf is splitted into hdr and payload.
o Remove unnecessary fields.
o spd is moved under send and recv.
- Remove unnecessary 'volatile' keyword.
- Add definition of rtcode and extcode.
* firewire.c
- Ignore FWDEVINVAL devices in fw_noderesolve_nodeid().
- Check the existance of the bind before call STAILQ_REMOVE().
- Fix bug in the fw_bindadd().
- Change element of struct fw_bind for simplicity.
- Check rtcode of response packet.
- Reduce split transaction timeout to 200 msec.
(100msec is the default value in the spec.)
- Set watchdog timer cycle to 10 Hz.
- Set xfer->tv just before calling fw_get_tlabel().
* fwohci.c
- Simplifies fwohci_get_plen().
* sbp.c
- Fix byte order of multibyte scsi_status informations.
- Split sbp.c and sbp.h.
- Unit number is not necessary for FIFO¤ address.
- Reduce LOGIN_DELAY and SCAN_DELAY to 1 sec.
- Add some constants defineded in SBP-2 spec.
* fwmem.c
- Introduce fwmem_strategy() and reduce memory copy.
Diffstat (limited to 'sys/dev/firewire/firewire.h')
-rw-r--r-- | sys/dev/firewire/firewire.h | 33 |
1 files changed, 27 insertions, 6 deletions
diff --git a/sys/dev/firewire/firewire.h b/sys/dev/firewire/firewire.h index ca9cbac..0063f47 100644 --- a/sys/dev/firewire/firewire.h +++ b/sys/dev/firewire/firewire.h @@ -190,12 +190,6 @@ struct fw_pkt { BIT16x2(src, dest_hi); u_int32_t dest_lo; BIT16x2(len, extcode); -#define FW_LREQ_MSKSWAP 1 -#define FW_LREQ_CMPSWAP 2 -#define FW_LREQ_FTADD 3 -#define FW_LREQ_LTADD 4 -#define FW_LREQ_BDADD 5 -#define FW_LREQ_WRADD 6 u_int32_t payload[0]; } lreq; struct { @@ -215,6 +209,33 @@ struct fw_pkt { } mode; }; +/* + * Response code (rtcode) + */ +/* The node has successfully completed the command. */ +#define RESP_CMP 0 +/* A resource conflict was detected. The request may be retried. */ +#define RESP_CONFLICT_ERROR 4 +/* Hardware error, data is unavailable. */ +#define RESP_DATA_ERROR 5 +/* A field in the request packet header was set to an unsupported or incorrect + * value, or an invalid transaction was attempted (e.g., a write to a read-only + * address). */ +#define RESP_TYPE_ERROR 6 +/* The destination offset field in the request was set to an address not + * accessible in the destination node. */ +#define RESP_ADDRESS_ERROR 7 + +/* + * Extended transaction code (extcode) + */ +#define EXTCODE_MASK_SWAP 1 +#define EXTCODE_CMP_SWAP 2 +#define EXTCODE_FETCH_ADD 3 +#define EXTCODE_LITTLE_ADD 4 +#define EXTCODE_BOUNDED_ADD 5 +#define EXTCODE_WRAP_ADD 6 + struct fw_eui64 { u_int32_t hi, lo; }; |