PERFORCE change 119747 for review

Sepherosa Ziehau sephe at FreeBSD.org
Sun May 13 04:14:27 UTC 2007


http://perforce.freebsd.org/chv.cgi?CH=119747

Change 119747 by sephe at sephe_zealot:sam_wifi on 2007/05/13 04:13:55

	u_intX_t -> uintX_t
	
	Approved by:	sam

Affected files ...

.. //depot/projects/wifi/sys/net80211/ieee80211_ht.c#2 edit
.. //depot/projects/wifi/sys/net80211/ieee80211_ht.h#2 edit

Differences ...

==== //depot/projects/wifi/sys/net80211/ieee80211_ht.c#2 (text+ko) ====

@@ -92,7 +92,7 @@
 static void ieee80211_addba_stop(struct ieee80211_node *ni,
 	struct ieee80211_tx_ampdu *tap);
 static void ieee80211_aggr_recv_action(struct ieee80211_node *ni,
-	const u_int8_t *frm, const u_int8_t *efrm);
+	const uint8_t *frm, const uint8_t *efrm);
 
 void
 ieee80211_ht_attach(struct ieee80211com *ic)
@@ -396,7 +396,7 @@
 	struct ieee80211_qosframe *wh;
 	struct ieee80211_rx_ampdu *rap;
 	ieee80211_seq rxseq;
-	u_int8_t tid;
+	uint8_t tid;
 	int off;
 
 	KASSERT(ni->ni_flags & IEEE80211_NODE_HT, ("not an HT sta"));
@@ -414,7 +414,7 @@
 		 */
 		return 0;
 	}
-	rxseq = le16toh(*(u_int16_t *)wh->i_seq) >> IEEE80211_SEQ_SEQ_SHIFT;
+	rxseq = le16toh(*(uint16_t *)wh->i_seq) >> IEEE80211_SEQ_SEQ_SHIFT;
 	if (rxseq == rap->rxa_start) {
 		/*
 		 * First frame in window.
@@ -600,7 +600,7 @@
  * work for temporary and/or legacy sta's.
  */
 void
-ieee80211_ht_node_init(struct ieee80211_node *ni, const u_int8_t *htcap)
+ieee80211_ht_node_init(struct ieee80211_node *ni, const uint8_t *htcap)
 {
 	struct ieee80211_tx_ampdu *tap;
 	int ac;
@@ -640,15 +640,15 @@
 
 /* unalligned little endian access */     
 #define LE_READ_2(p)					\
-	((u_int16_t)					\
-	 ((((const u_int8_t *)(p))[0]      ) |		\
-	  (((const u_int8_t *)(p))[1] <<  8)))
+	((uint16_t)					\
+	 ((((const uint8_t *)(p))[0]      ) |		\
+	  (((const uint8_t *)(p))[1] <<  8)))
 
 /*
  * Process an 802.11n HT capabilities ie.
  */
 void
-ieee80211_parse_htcap(struct ieee80211_node *ni, const u_int8_t *ie)
+ieee80211_parse_htcap(struct ieee80211_node *ni, const uint8_t *ie)
 {
 	struct ieee80211com *ic = ni->ni_ic;
 
@@ -682,7 +682,7 @@
  * Process an 802.11n HT info ie.
  */
 void
-ieee80211_parse_htinfo(struct ieee80211_node *ni, const u_int8_t *ie)
+ieee80211_parse_htinfo(struct ieee80211_node *ni, const uint8_t *ie)
 {
  	const struct ieee80211_ie_htinfo *htinfo;
 	uint16_t w;
@@ -709,7 +709,7 @@
  * Install received HT rate set by parsing the HT cap ie.
  */
 int
-ieee80211_setup_htrates(struct ieee80211_node *ni, const u_int8_t *ie, int flags)
+ieee80211_setup_htrates(struct ieee80211_node *ni, const uint8_t *ie, int flags)
 {
 	struct ieee80211com *ic = ni->ni_ic;
 	const struct ieee80211_ie_htcap *htcap;
@@ -744,7 +744,7 @@
  * to the information in the supplied HT info ie.
  */
 void
-ieee80211_setup_basic_htrates(struct ieee80211_node *ni, const u_int8_t *ie)
+ieee80211_setup_basic_htrates(struct ieee80211_node *ni, const uint8_t *ie)
 {
 	const struct ieee80211_ie_htinfo *htinfo;
 	struct ieee80211_htrateset *rs;
@@ -871,15 +871,15 @@
  */
 static void
 ieee80211_aggr_recv_action(struct ieee80211_node *ni,
-	const u_int8_t *frm, const u_int8_t *efrm)
+	const uint8_t *frm, const uint8_t *efrm)
 {
 	struct ieee80211com *ic = ni->ni_ic;
 	const struct ieee80211_action *ia;
 	struct ieee80211_rx_ampdu *rap;
 	struct ieee80211_tx_ampdu *tap;
-	u_int8_t dialogtoken;
-	u_int16_t baparamset, batimeout, baseqctl, code;
-	u_int16_t args[4];
+	uint8_t dialogtoken;
+	uint16_t baparamset, batimeout, baseqctl, code;
+	uint16_t args[4];
 	int tid, ac, bufsiz;
 
 	ia = (const struct ieee80211_action *) frm;
@@ -981,7 +981,7 @@
  */
 void
 ieee80211_recv_action(struct ieee80211_node *ni,
-	const u_int8_t *frm, const u_int8_t *efrm)
+	const uint8_t *frm, const uint8_t *efrm)
 {
 	struct ieee80211com *ic = ni->ni_ic;
 	const struct ieee80211_action *ia;
@@ -1044,7 +1044,7 @@
 	struct ieee80211_tx_ampdu *tap)
 {
 	struct ieee80211com *ic = ni->ni_ic;
-	u_int16_t args[4];
+	uint16_t args[4];
 	int tid, dialogtoken;
 	static int tokens = 0;	/* XXX */
 
@@ -1106,8 +1106,8 @@
 	struct ifnet *ifp = ic->ic_ifp;
 	struct ieee80211_frame_min *wh;
 	struct mbuf *m;
-	u_int8_t *frm;
-	u_int16_t barctl, barseqctl;
+	uint8_t *frm;
+	uint16_t barctl, barseqctl;
 	int tid, ret;
 
 	ieee80211_ref_node(ni);
@@ -1138,7 +1138,7 @@
 		;
 	ADDSHORT(frm, barctl);
 	ADDSHORT(frm, barseqctl);
-	m->m_pkthdr.len = m->m_len = frm - mtod(m, u_int8_t *);
+	m->m_pkthdr.len = m->m_len = frm - mtod(m, uint8_t *);
 
 	IEEE80211_NODE_STAT(ni, tx_mgmt);	/* XXX tx_ctl? */
 
@@ -1166,7 +1166,7 @@
  */
 int
 ieee80211_send_action(struct ieee80211_node *ni,
-	int category, int action, u_int16_t args[4])
+	int category, int action, uint16_t args[4])
 {
 #define	senderr(_x, _v)	do { ic->ic_stats._v++; ret = _x; goto bad; } while (0)
 #define	ADDSHORT(frm, v) do {			\
@@ -1176,8 +1176,8 @@
 } while (0)
 	struct ieee80211com *ic = ni->ni_ic;
 	struct mbuf *m;
-	u_int8_t *frm;
-	u_int16_t baparamset;
+	uint8_t *frm;
+	uint16_t baparamset;
 	int ret;
 
 	KASSERT(ni != NULL, ("null node"));
@@ -1196,7 +1196,7 @@
 
 	m = ieee80211_getmgtframe(&frm,
 		ic->ic_headroom + sizeof(struct ieee80211_frame),
-		  sizeof(u_int16_t)	/* action+category */
+		  sizeof(uint16_t)	/* action+category */
 		/* XXX may action payload */
 		+ sizeof(struct ieee80211_action_ba_addbaresponse)
 	);
@@ -1274,7 +1274,7 @@
 		senderr(EINVAL, is_tx_unknownmgt);
 		/* NOTREACHED */
 	}
-	m->m_pkthdr.len = m->m_len = frm - mtod(m, u_int8_t *);
+	m->m_pkthdr.len = m->m_len = frm - mtod(m, uint8_t *);
 
 	ret = ieee80211_mgmt_output(ic, ni, m, IEEE80211_FC0_SUBTYPE_ACTION);
 	if (ret != 0)
@@ -1292,7 +1292,7 @@
  * in an HT information element.
  */
 static void 
-ieee80211_set_htrates(u_int8_t *frm, const struct ieee80211_htrateset *rs)
+ieee80211_set_htrates(uint8_t *frm, const struct ieee80211_htrateset *rs)
 {
 	int i;
 
@@ -1308,8 +1308,8 @@
 /*
  * Add body of an HTCAP information element.
  */
-static u_int8_t *
-ieee80211_add_htcap_body(u_int8_t *frm, struct ieee80211_node *ni)
+static uint8_t *
+ieee80211_add_htcap_body(uint8_t *frm, struct ieee80211_node *ni)
 {
 #define	ADDSHORT(frm, v) do {			\
 	frm[0] = (v) & 0xff;			\
@@ -1317,7 +1317,7 @@
 	frm += 2;				\
 } while (0)
 	struct ieee80211com *ic = ni->ni_ic;
-	u_int16_t caps;
+	uint16_t caps;
 
 	/* HT capabilities */
 	caps = ic->ic_htcaps & 0xffff;
@@ -1361,8 +1361,8 @@
 /*
  * Add 802.11n HT capabilities information element
  */
-u_int8_t *
-ieee80211_add_htcap(u_int8_t *frm, struct ieee80211_node *ni)
+uint8_t *
+ieee80211_add_htcap(uint8_t *frm, struct ieee80211_node *ni)
 {
 	frm[0] = IEEE80211_ELEMID_HTCAP;
 	frm[1] = sizeof(struct ieee80211_ie_htcap) - 2;
@@ -1373,8 +1373,8 @@
  * Add Broadcom OUI wrapped standard HTCAP ie; this is
  * used for compatibility w/ pre-draft implementations.
  */
-u_int8_t *
-ieee80211_add_htcap_vendor(u_int8_t *frm, struct ieee80211_node *ni)
+uint8_t *
+ieee80211_add_htcap_vendor(uint8_t *frm, struct ieee80211_node *ni)
 {
 	frm[0] = IEEE80211_ELEMID_VENDOR;
 	frm[1] = 4 + sizeof(struct ieee80211_ie_htcap) - 2;
@@ -1390,7 +1390,7 @@
  * for inclusion in an HT information element.
  */
 static void
-ieee80211_set_basic_htrates(u_int8_t *frm, const struct ieee80211_htrateset *rs)
+ieee80211_set_basic_htrates(uint8_t *frm, const struct ieee80211_htrateset *rs)
 {
 	int i;
 
@@ -1407,8 +1407,8 @@
 /*
  * Add body of an HTINFO information element.
  */
-static u_int8_t *
-ieee80211_add_htinfo_body(u_int8_t *frm, struct ieee80211_node *ni)
+static uint8_t *
+ieee80211_add_htinfo_body(uint8_t *frm, struct ieee80211_node *ni)
 {
 	struct ieee80211com *ic = ni->ni_ic;
 
@@ -1444,8 +1444,8 @@
 /*
  * Add 802.11n HT information information element.
  */
-u_int8_t *
-ieee80211_add_htinfo(u_int8_t *frm, struct ieee80211_node *ni)
+uint8_t *
+ieee80211_add_htinfo(uint8_t *frm, struct ieee80211_node *ni)
 {
 	frm[0] = IEEE80211_ELEMID_HTINFO;
 	frm[1] = sizeof(struct ieee80211_ie_htinfo) - 2;
@@ -1456,8 +1456,8 @@
  * Add Broadcom OUI wrapped standard HTINFO ie; this is
  * used for compatibility w/ pre-draft implementations.
  */
-u_int8_t *
-ieee80211_add_htinfo_vendor(u_int8_t *frm, struct ieee80211_node *ni)
+uint8_t *
+ieee80211_add_htinfo_vendor(uint8_t *frm, struct ieee80211_node *ni)
 {
 	frm[0] = IEEE80211_ELEMID_VENDOR;
 	frm[1] = 4 + sizeof(struct ieee80211_ie_htinfo) - 2;

==== //depot/projects/wifi/sys/net80211/ieee80211_ht.h#2 (text+ko) ====

@@ -36,7 +36,7 @@
 
 #define	IEEE80211_AGGR_BAWMAX	64	/* max block ack window size */
 
-typedef u_int16_t ieee80211_seq;
+typedef uint16_t ieee80211_seq;
 
 struct ieee80211_tx_ampdu {
 	u_short		txa_flags;
@@ -44,14 +44,14 @@
 #define	IEEE80211_AGGR_XCHGPEND		0x0002	/* ADDBA response pending */
 #define	IEEE80211_AGGR_RUNNING		0x0004	/* ADDBA response received */
 #define	IEEE80211_AGGR_SETUP		0x0008	/* deferred state setup */
-	u_int8_t	txa_ac;
-	u_int8_t	txa_token;	/* dialog token */
+	uint8_t		txa_ac;
+	uint8_t		txa_token;	/* dialog token */
 	int		txa_qbytes;	/* data queued (bytes) */
 	short		txa_qframes;	/* data queued (frames) */
 	ieee80211_seq	txa_seqstart;
 	ieee80211_seq	txa_start;
-	u_int16_t	txa_wnd;	/* BA window size */
-	u_int8_t	txa_attempts;	/* # setup attempts */
+	uint16_t	txa_wnd;	/* BA window size */
+	uint8_t		txa_attempts;	/* # setup attempts */
 	int		txa_lastrequest;/* time of last ADDBA request */
 	struct ifqueue	txa_q;		/* packet queue */
 	struct callout	txa_timer;
@@ -73,7 +73,7 @@
 	ieee80211_seq	rxa_seqstart;
 	ieee80211_seq	rxa_start;	/* start of current BA window */
 	ieee80211_seq	rxa_nxt;	/* next seq# in BA window */
-	u_int16_t	rxa_wnd;	/* BA window size */
+	uint16_t	rxa_wnd;	/* BA window size */
 	struct mbuf *rxa_m[IEEE80211_AGGR_BAWMAX];
 };
 
@@ -88,26 +88,26 @@
 
 struct ieee80211_node;
 int	ieee80211_setup_htrates(struct ieee80211_node *,
-		const u_int8_t *htcap, int flags);
+		const uint8_t *htcap, int flags);
 void	ieee80211_setup_basic_htrates(struct ieee80211_node *,
-		const u_int8_t *htinfo);
+		const uint8_t *htinfo);
 struct mbuf *ieee80211_decap_amsdu(struct ieee80211_node *, struct mbuf *);
 int	ieee80211_ampdu_reorder(struct ieee80211_node *, struct mbuf *);
 void	ieee80211_recv_bar(struct ieee80211_node *, struct mbuf *);
-void	ieee80211_ht_node_init(struct ieee80211_node *, const u_int8_t *);
+void	ieee80211_ht_node_init(struct ieee80211_node *, const uint8_t *);
 void	ieee80211_ht_node_cleanup(struct ieee80211_node *);
-void	ieee80211_parse_htcap(struct ieee80211_node *, const u_int8_t *);
-void	ieee80211_parse_htinfo(struct ieee80211_node *, const u_int8_t *);
+void	ieee80211_parse_htcap(struct ieee80211_node *, const uint8_t *);
+void	ieee80211_parse_htinfo(struct ieee80211_node *, const uint8_t *);
 void	ieee80211_recv_action(struct ieee80211_node *,
-		const u_int8_t *, const u_int8_t *);
+		const uint8_t *, const uint8_t *);
 int	ieee80211_ampdu_request(struct ieee80211_node *,
 		struct ieee80211_tx_ampdu *);
 int	ieee80211_send_bar(struct ieee80211_node *,
 		const struct ieee80211_tx_ampdu *);
 int	ieee80211_send_action(struct ieee80211_node *,
-		int, int, u_int16_t [4]);
-u_int8_t *ieee80211_add_htcap(u_int8_t *, struct ieee80211_node *);
-u_int8_t *ieee80211_add_htcap_vendor(u_int8_t *, struct ieee80211_node *);
-u_int8_t *ieee80211_add_htinfo(u_int8_t *, struct ieee80211_node *);
-u_int8_t *ieee80211_add_htinfo_vendor(u_int8_t *, struct ieee80211_node *);
+		int, int, uint16_t [4]);
+uint8_t	*ieee80211_add_htcap(uint8_t *, struct ieee80211_node *);
+uint8_t	*ieee80211_add_htcap_vendor(uint8_t *, struct ieee80211_node *);
+uint8_t	*ieee80211_add_htinfo(uint8_t *, struct ieee80211_node *);
+uint8_t	*ieee80211_add_htinfo_vendor(uint8_t *, struct ieee80211_node *);
 #endif /* _NET80211_IEEE80211_HT_H_ */


More information about the p4-projects mailing list