| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Conexant cx24123/cx24109 - DVB QPSK Satellite demod/tuner driver |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 6 | 7 | * Support for KWorld DVB-S 100 by Vadim Catana <skystar@moldova.cc> |
|---|
| 7 | 8 | * |
|---|
| 8 | 9 | * Support for CX24123/CX24113-NIM by Patrick Boettcher <pb@linuxtv.org> |
|---|
| 9 | | - * |
|---|
| 10 | | - * This program is free software; you can redistribute it and/or |
|---|
| 11 | | - * modify it under the terms of the GNU General Public License as |
|---|
| 12 | | - * published by the Free Software Foundation; either version 2 of |
|---|
| 13 | | - * the License, or (at your option) any later version. |
|---|
| 14 | | - * |
|---|
| 15 | | - * This program is distributed in the hope that it will be useful, |
|---|
| 16 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 17 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|---|
| 18 | | - * General Public License for more details. |
|---|
| 19 | 10 | */ |
|---|
| 20 | 11 | |
|---|
| 21 | 12 | #include <linux/slab.h> |
|---|
| .. | .. |
|---|
| 440 | 431 | u32 div = a / b; |
|---|
| 441 | 432 | if (a % b >= b / 2) |
|---|
| 442 | 433 | ++div; |
|---|
| 443 | | - if (div < (1 << 31)) { |
|---|
| 434 | + if (div < (1UL << 31)) { |
|---|
| 444 | 435 | for (exp = 1; div > exp; nearest++) |
|---|
| 445 | 436 | exp += exp; |
|---|
| 446 | 437 | } |
|---|
| .. | .. |
|---|
| 1087 | 1078 | if (config->dont_use_pll) |
|---|
| 1088 | 1079 | cx24123_repeater_mode(state, 1, 0); |
|---|
| 1089 | 1080 | |
|---|
| 1090 | | - strlcpy(state->tuner_i2c_adapter.name, "CX24123 tuner I2C bus", |
|---|
| 1081 | + strscpy(state->tuner_i2c_adapter.name, "CX24123 tuner I2C bus", |
|---|
| 1091 | 1082 | sizeof(state->tuner_i2c_adapter.name)); |
|---|
| 1092 | 1083 | state->tuner_i2c_adapter.algo = &cx24123_tuner_i2c_algo; |
|---|
| 1093 | 1084 | state->tuner_i2c_adapter.algo_data = NULL; |
|---|
| .. | .. |
|---|
| 1105 | 1096 | |
|---|
| 1106 | 1097 | return NULL; |
|---|
| 1107 | 1098 | } |
|---|
| 1108 | | -EXPORT_SYMBOL(cx24123_attach); |
|---|
| 1099 | +EXPORT_SYMBOL_GPL(cx24123_attach); |
|---|
| 1109 | 1100 | |
|---|
| 1110 | 1101 | static const struct dvb_frontend_ops cx24123_ops = { |
|---|
| 1111 | 1102 | .delsys = { SYS_DVBS }, |
|---|