PERFORCE change 156213 for review

Weongyo Jeong weongyo at FreeBSD.org
Thu Jan 15 01:28:51 PST 2009


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

Change 156213 by weongyo at weongyo_ws on 2009/01/15 09:28:28

	whitespace tweak.

Affected files ...

.. //depot/projects/vap/sys/dev/usb/if_urtw.c#18 edit

Differences ...

==== //depot/projects/vap/sys/dev/usb/if_urtw.c#18 (text+ko) ====

@@ -225,18 +225,18 @@
 	{ 0x4a, 0x05 }, { 0x4b, 0x02 }, { 0x4c, 0x05 }
 };
 
-static uint16_t urtw_8225_rxgain[] = {	
+static uint16_t urtw_8225_rxgain[] = {
 	0x0400, 0x0401, 0x0402, 0x0403, 0x0404, 0x0405, 0x0408, 0x0409,
-	0x040a, 0x040b, 0x0502, 0x0503, 0x0504, 0x0505, 0x0540, 0x0541,  
+	0x040a, 0x040b, 0x0502, 0x0503, 0x0504, 0x0505, 0x0540, 0x0541,
 	0x0542, 0x0543, 0x0544, 0x0545, 0x0580, 0x0581, 0x0582, 0x0583,
-	0x0584, 0x0585, 0x0588, 0x0589, 0x058a, 0x058b, 0x0643, 0x0644, 
+	0x0584, 0x0585, 0x0588, 0x0589, 0x058a, 0x058b, 0x0643, 0x0644,
 	0x0645, 0x0680, 0x0681, 0x0682, 0x0683, 0x0684, 0x0685, 0x0688,
 	0x0689, 0x068a, 0x068b, 0x068c, 0x0742, 0x0743, 0x0744, 0x0745,
 	0x0780, 0x0781, 0x0782, 0x0783, 0x0784, 0x0785, 0x0788, 0x0789,
 	0x078a, 0x078b, 0x078c, 0x078d, 0x0790, 0x0791, 0x0792, 0x0793,
-	0x0794, 0x0795, 0x0798, 0x0799, 0x079a, 0x079b, 0x079c, 0x079d,  
-	0x07a0, 0x07a1, 0x07a2, 0x07a3, 0x07a4, 0x07a5, 0x07a8, 0x07a9,  
-	0x07aa, 0x07ab, 0x07ac, 0x07ad, 0x07b0, 0x07b1, 0x07b2, 0x07b3,  
+	0x0794, 0x0795, 0x0798, 0x0799, 0x079a, 0x079b, 0x079c, 0x079d,
+	0x07a0, 0x07a1, 0x07a2, 0x07a3, 0x07a4, 0x07a5, 0x07a8, 0x07a9,
+	0x07aa, 0x07ab, 0x07ac, 0x07ad, 0x07b0, 0x07b1, 0x07b2, 0x07b3,
 	0x07b4, 0x07b5, 0x07b8, 0x07b9, 0x07ba, 0x07bb, 0x07bb
 };
 
@@ -272,12 +272,12 @@
 
 static uint8_t urtw_8225v2_gain_bg[]={
 	0x23, 0x15, 0xa5,		/* -82-1dbm  */
-        0x23, 0x15, 0xb5,		/* -82-2dbm  */
-        0x23, 0x15, 0xc5,		/* -82-3dbm  */
-        0x33, 0x15, 0xc5,		/* -78dbm  */
-        0x43, 0x15, 0xc5,		/* -74dbm  */
-        0x53, 0x15, 0xc5,		/* -70dbm  */
-        0x63, 0x15, 0xc5,		/* -66dbm  */
+	0x23, 0x15, 0xb5,		/* -82-2dbm  */
+	0x23, 0x15, 0xc5,		/* -82-3dbm  */
+	0x33, 0x15, 0xc5,		/* -78dbm  */
+	0x43, 0x15, 0xc5,		/* -74dbm  */
+	0x53, 0x15, 0xc5,		/* -70dbm  */
+	0x63, 0x15, 0xc5,		/* -66dbm  */
 };
 
 static struct urtw_pair urtw_8225v2_rf_part1[] = {
@@ -312,17 +312,17 @@
 };
 
 static uint16_t urtw_8225v2_rxgain[] = {
-        0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0008, 0x0009,
-	0x000a,	0x000b, 0x0102, 0x0103, 0x0104, 0x0105, 0x0140, 0x0141,	  
-        0x0142,	0x0143, 0x0144, 0x0145, 0x0180, 0x0181, 0x0182, 0x0183,
-	0x0184,	0x0185, 0x0188, 0x0189, 0x018a, 0x018b, 0x0243, 0x0244,	 
-	0x0245,	0x0280, 0x0281, 0x0282, 0x0283, 0x0284, 0x0285, 0x0288,
-        0x0289, 0x028a, 0x028b, 0x028c, 0x0342, 0x0343, 0x0344, 0x0345,
+	0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0008, 0x0009,
+	0x000a, 0x000b, 0x0102, 0x0103, 0x0104, 0x0105, 0x0140, 0x0141,
+	0x0142, 0x0143, 0x0144, 0x0145, 0x0180, 0x0181, 0x0182, 0x0183,
+	0x0184, 0x0185, 0x0188, 0x0189, 0x018a, 0x018b, 0x0243, 0x0244,
+	0x0245, 0x0280, 0x0281, 0x0282, 0x0283, 0x0284, 0x0285, 0x0288,
+	0x0289, 0x028a, 0x028b, 0x028c, 0x0342, 0x0343, 0x0344, 0x0345,
 	0x0380, 0x0381, 0x0382, 0x0383, 0x0384, 0x0385, 0x0388, 0x0389,
 	0x038a, 0x038b, 0x038c, 0x038d, 0x0390, 0x0391, 0x0392, 0x0393,
-	0x0394, 0x0395, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d,	  
-	0x03a0, 0x03a1, 0x03a2, 0x03a3, 0x03a4, 0x03a5, 0x03a8, 0x03a9,	  
-	0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03b0, 0x03b1, 0x03b2, 0x03b3,	
+	0x0394, 0x0395, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d,
+	0x03a0, 0x03a1, 0x03a2, 0x03a3, 0x03a4, 0x03a5, 0x03a8, 0x03a9,
+	0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03b0, 0x03b1, 0x03b2, 0x03b3,
 	0x03b4, 0x03b5, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bb
 };
 
@@ -410,19 +410,19 @@
 static usbd_status	urtw_led_init(struct urtw_softc *);
 static usbd_status	urtw_8185_rf_pins_enable(struct urtw_softc *);
 static usbd_status	urtw_8185_tx_antenna(struct urtw_softc *, uint8_t);
-static usbd_status	urtw_8187_write_phy(struct urtw_softc *, uint8_t, 
+static usbd_status	urtw_8187_write_phy(struct urtw_softc *, uint8_t,
 			    uint32_t);
-static usbd_status	urtw_8187_write_phy_ofdm_c(struct urtw_softc *, 
+static usbd_status	urtw_8187_write_phy_ofdm_c(struct urtw_softc *,
 			    uint8_t, uint32_t);
-static usbd_status	urtw_8187_write_phy_cck_c(struct urtw_softc *, uint8_t, 
+static usbd_status	urtw_8187_write_phy_cck_c(struct urtw_softc *, uint8_t,
 			    uint32_t);
 static usbd_status	urtw_8225_setgain(struct urtw_softc *, int16_t);
 static usbd_status	urtw_8225_usb_init(struct urtw_softc *);
-static usbd_status	urtw_8225_write_c(struct urtw_softc *, uint8_t, 
+static usbd_status	urtw_8225_write_c(struct urtw_softc *, uint8_t,
 			    uint16_t);
-static usbd_status	urtw_8225_write_s16(struct urtw_softc *, uint8_t, int, 
+static usbd_status	urtw_8225_write_s16(struct urtw_softc *, uint8_t, int,
 			    uint16_t *);
-static usbd_status	urtw_8225_read(struct urtw_softc *, uint8_t, 
+static usbd_status	urtw_8225_read(struct urtw_softc *, uint8_t,
 			    uint32_t *);
 static usbd_status	urtw_8225_rf_init(struct urtw_softc *);
 static usbd_status	urtw_8225_rf_set_chan(struct urtw_softc *, int);
@@ -1076,7 +1076,7 @@
 {
 	uint32_t data;
 	usbd_status error;
-	
+
 	error = urtw_eprom_read32(sc, URTW_EPROM_MACADDR, &data);
 	if (error != 0)
 		goto fail;
@@ -1556,7 +1556,7 @@
 		device_printf(sc->sc_dev, "reset timeout\n");
 		goto fail;
 	}
-	
+
 	error = urtw_set_mode(sc, URTW_EPROM_CMD_LOAD);
 	if (error)
 		goto fail;
@@ -1730,7 +1730,7 @@
 
 	sc->sc_gpio_blinkstate = (sc->sc_gpio_blinkstate != URTW_LED_ON) ?
 	    URTW_LED_ON : URTW_LED_OFF;
-	
+
 	switch (sc->sc_gpio_ledstate) {
 	case URTW_LED_BLINK_NORMAL:
 		callout_reset(&sc->sc_led_ch, hz, urtw_ledtask, sc);
@@ -1867,7 +1867,7 @@
 	basic_rate = urtw_rate2rtl(48);
 	min_rr_rate = urtw_rate2rtl(12);
 	max_rr_rate = urtw_rate2rtl(48);
-	
+
 	urtw_write8_m(sc, URTW_RESP_RATE,
 	    max_rr_rate << URTW_RESP_MAX_RATE_SHIFT |
 	    min_rr_rate << URTW_RESP_MIN_RATE_SHIFT);
@@ -1987,7 +1987,7 @@
 		data = data | URTW_RX_FILTER_NICMAC;
 		data = data | URTW_RX_CHECK_BSSID;
 	}
-	
+
 	data = data &~ URTW_RX_FIFO_THRESHOLD_MASK;
 	data = data | URTW_RX_FIFO_THRESHOLD_NONE | URTW_RX_AUTORESETPHY;
 	data = data &~ URTW_MAX_RX_DMA_MASK;
@@ -2264,7 +2264,7 @@
 		m_freem(m);
 		data->m = NULL;
 	}
-	
+
 	ieee80211_free_node(data->ni);
 	data->ni = NULL;
 
@@ -2355,7 +2355,7 @@
 			m_freem(m0);
 			return (ENOBUFS);
 		}
-		
+
 		/* in case packet header moved, reset pointer */
 		wh = mtod(m0, struct ieee80211_frame *);
 	}
@@ -2608,7 +2608,7 @@
 	uint8_t cck_pwrlvl = sc->sc_txpwr_cck[chan] & 0xff;
 	uint8_t ofdm_pwrlvl = sc->sc_txpwr_ofdm[chan] & 0xff;
 	usbd_status error;
-	
+
 	cck_pwrlvl_max = 11;
 	ofdm_pwrlvl_max = 25;	/* 12 -> 25  */
 	ofdm_pwrlvl_min = 10;
@@ -2627,12 +2627,12 @@
 		    cck_pwltable[idx * 8 + i]);
 	}
 	usbd_delay_ms(sc->sc_udev, 1);
-	
+
 	/* OFDM power setting */
 	ofdm_pwrlvl = (ofdm_pwrlvl > (ofdm_pwrlvl_max - ofdm_pwrlvl_min)) ?
 	    ofdm_pwrlvl_max : ofdm_pwrlvl + ofdm_pwrlvl_min;
 	ofdm_pwrlvl = (ofdm_pwrlvl > 35) ? 35 : ofdm_pwrlvl;
-	
+
 	idx = ofdm_pwrlvl % 6;
 	set = ofdm_pwrlvl / 6;
 
@@ -2711,7 +2711,7 @@
 	usbd_delay_ms(sc->sc_udev, 200);
 	urtw_8225_write(sc,
 	    URTW_8225_ADDR_0_MAGIC, URTW_8225_ADDR_0_DATA_MAGIC3);
-	
+
 	for (i = 0; i < 95; i++) {
 		urtw_8225_write(sc, URTW_8225_ADDR_1_MAGIC, (uint8_t)(i + 1));
 		urtw_8225_write(sc, URTW_8225_ADDR_2_MAGIC, urtw_8225_rxgain[i]);
@@ -2721,7 +2721,7 @@
 	    URTW_8225_ADDR_0_MAGIC, URTW_8225_ADDR_0_DATA_MAGIC4);
 	urtw_8225_write(sc,
 	    URTW_8225_ADDR_0_MAGIC, URTW_8225_ADDR_0_DATA_MAGIC5);
-	
+
 	for (i = 0; i < 128; i++) {
 		urtw_8187_write_phy_ofdm(sc, 0xb, urtw_8225_agc[i]);
 		usbd_delay_ms(sc->sc_udev, 1);
@@ -2734,7 +2734,7 @@
 		    urtw_8225_rf_part2[i].val);
 		usbd_delay_ms(sc->sc_udev, 1);
 	}
-	
+
 	error = urtw_8225_setgain(sc, 4);
 	if (error)
 		goto fail;
@@ -2750,7 +2750,7 @@
 	error = urtw_8225_set_txpwrlvl(sc, 1);
 	if (error)
 		goto fail;
-	
+
 	urtw_8187_write_phy_cck(sc, 0x10, 0x9b);
 	usbd_delay_ms(sc->sc_udev, 1);
 	urtw_8187_write_phy_ofdm(sc, 0x26, 0x90);
@@ -2788,7 +2788,7 @@
 		urtw_write8_m(sc, URTW_SLOT, 0x9);
 	else
 		urtw_write8_m(sc, URTW_SLOT, 0x14);
-	
+
 	if (IEEE80211_IS_CHAN_G(c)) {
 		/* for G */
 		urtw_write8_m(sc, URTW_DIFS, 0x14);
@@ -2816,7 +2816,7 @@
 	if (sens > 4)
 		urtw_8225_write(sc,
 		    URTW_8225_ADDR_C_MAGIC, URTW_8225_ADDR_C_DATA_MAGIC1);
-	else	
+	else
 		urtw_8225_write(sc,
 		    URTW_8225_ADDR_C_MAGIC, URTW_8225_ADDR_C_DATA_MAGIC2);
 
@@ -2824,7 +2824,7 @@
 	error = urtw_8225_setgain(sc, sens);
 	if (error)
 		goto fail;
-	
+
 	urtw_8187_write_phy_cck(sc, 0x41, urtw_8225_threshold[sens]);
 
 fail:
@@ -2915,7 +2915,7 @@
 		ifp->if_ierrors++;
 		goto skip;
 	}
-	
+
 	m = data->m;
 	data->m = mnew;
 	data->buf = mtod(mnew, uint8_t *);
@@ -3024,7 +3024,7 @@
 	urtw_write8_m(sc, URTW_TX_GAIN_CCK,
 	    urtw_8225v2_tx_gain_cck_ofdm[cck_pwrlvl]);
 	usbd_delay_ms(sc->sc_udev, 1);
-	
+
 	/* OFDM power setting */
 	ofdm_pwrlvl = (ofdm_pwrlvl > (ofdm_pwrlvl_max - ofdm_pwrlvl_min)) ?
 		ofdm_pwrlvl_max : ofdm_pwrlvl + ofdm_pwrlvl_min;
@@ -3143,7 +3143,7 @@
 		urtw_8187_write_phy_ofdm(sc, urtw_8225v2_rf_part2[i].reg,
 		    urtw_8225v2_rf_part2[i].val);
 	}
-	
+
 	error = urtw_8225v2_setgain(sc, 4);
 	if (error)
 		goto fail;
@@ -3158,7 +3158,7 @@
 	error = urtw_8225v2_set_txpwrlvl(sc, 1);
 	if (error)
 		goto fail;
-	
+
 	urtw_8187_write_phy_cck(sc, 0x10, 0x9b);
 	urtw_8187_write_phy_ofdm(sc, 0x26, 0x90);
 
@@ -3195,7 +3195,7 @@
 		urtw_write8_m(sc, URTW_SLOT, 0x9);
 	else
 		urtw_write8_m(sc, URTW_SLOT, 0x14);
-	
+
 	if (IEEE80211_IS_CHAN_G(c)) {
 		/* for G */
 		urtw_write8_m(sc, URTW_DIFS, 0x14);
@@ -3267,7 +3267,7 @@
 		urtw_update_msr(sc);
 		/* XXX maybe the below would be incorrect.  */
 		urtw_write16_m(sc, URTW_ATIM_WND, 2);
-		urtw_write16_m(sc, URTW_ATIM_TR_ITV, 100);	
+		urtw_write16_m(sc, URTW_ATIM_TR_ITV, 100);
 		urtw_write16_m(sc, URTW_BEACON_INTERVAL, 0x64);
 		urtw_write16_m(sc, URTW_BEACON_INTERVAL_TIME, 100);
 		error = urtw_led_ctl(sc, URTW_LED_CTL_LINK);


More information about the p4-projects mailing list