Deleted Added
full compact
if_run.c (258919) if_run.c (258921)
1/*-
2 * Copyright (c) 2008,2010 Damien Bergamini <damien.bergamini@free.fr>
3 * ported to FreeBSD by Akinori Furukoshi <moonlightakkiy@yahoo.ca>
4 * USB Consulting, Hans Petter Selasky <hselasky@freebsd.org>
5 *
6 * Permission to use, copy, modify, and distribute this software for any
7 * purpose with or without fee is hereby granted, provided that the above
8 * copyright notice and this permission notice appear in all copies.
9 *
10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */
18
19#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2008,2010 Damien Bergamini <damien.bergamini@free.fr>
3 * ported to FreeBSD by Akinori Furukoshi <moonlightakkiy@yahoo.ca>
4 * USB Consulting, Hans Petter Selasky <hselasky@freebsd.org>
5 *
6 * Permission to use, copy, modify, and distribute this software for any
7 * purpose with or without fee is hereby granted, provided that the above
8 * copyright notice and this permission notice appear in all copies.
9 *
10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */
18
19#include <sys/cdefs.h>
20__FBSDID("$FreeBSD: head/sys/dev/usb/wlan/if_run.c 258919 2013-12-04 12:07:46Z hselasky $");
20__FBSDID("$FreeBSD: head/sys/dev/usb/wlan/if_run.c 258921 2013-12-04 12:30:51Z hselasky $");
21
22/*-
23 * Ralink Technology RT2700U/RT2800U/RT3000U/RT3900E chipset driver.
24 * http://www.ralinktech.com/
25 */
26
27#include <sys/param.h>
28#include <sys/sockio.h>

--- 3638 unchanged lines hidden (view full) ---

3667 } else {
3668 txpow1 += 7;
3669
3670 /* txpow1 is not possible larger than 15. */
3671 r3 |= (txpow1 << 10);
3672 }
3673 if (txpow2 >= 0) {
3674 txpow2 = (txpow2 > 0xf) ? (0xf) : (txpow2);
21
22/*-
23 * Ralink Technology RT2700U/RT2800U/RT3000U/RT3900E chipset driver.
24 * http://www.ralinktech.com/
25 */
26
27#include <sys/param.h>
28#include <sys/sockio.h>

--- 3638 unchanged lines hidden (view full) ---

3667 } else {
3668 txpow1 += 7;
3669
3670 /* txpow1 is not possible larger than 15. */
3671 r3 |= (txpow1 << 10);
3672 }
3673 if (txpow2 >= 0) {
3674 txpow2 = (txpow2 > 0xf) ? (0xf) : (txpow2);
3675 r4 |= (txpow1 << 7) | (1 << 6);
3675 r4 |= (txpow2 << 7) | (1 << 6);
3676 } else {
3677 txpow2 += 7;
3678 r4 |= (txpow2 << 7);
3679 }
3680 } else {
3681 /* Set Tx0 power. */
3682 r3 |= (txpow1 << 9);
3683

--- 1689 unchanged lines hidden ---
3676 } else {
3677 txpow2 += 7;
3678 r4 |= (txpow2 << 7);
3679 }
3680 } else {
3681 /* Set Tx0 power. */
3682 r3 |= (txpow1 << 9);
3683

--- 1689 unchanged lines hidden ---