.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
---|
1 | 2 | /* |
---|
2 | 3 | * Driver for Xceive XC4000 "QAM/8VSB single chip tuner" |
---|
3 | 4 | * |
---|
.. | .. |
---|
6 | 7 | * Copyright (c) 2009 Devin Heitmueller <dheitmueller@kernellabs.com> |
---|
7 | 8 | * Copyright (c) 2009 Davide Ferri <d.ferri@zero11.it> |
---|
8 | 9 | * Copyright (c) 2010 Istvan Varga <istvan_v@mailbox.hu> |
---|
9 | | - * |
---|
10 | | - * This program is free software; you can redistribute it and/or modify |
---|
11 | | - * it under the terms of the GNU General Public License as published by |
---|
12 | | - * the Free Software Foundation; either version 2 of the License, or |
---|
13 | | - * (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 |
---|
18 | | - * GNU General Public License for more details. |
---|
19 | 10 | */ |
---|
20 | 11 | |
---|
21 | 12 | #include <linux/module.h> |
---|
.. | .. |
---|
821 | 812 | goto corrupt; |
---|
822 | 813 | } |
---|
823 | 814 | |
---|
824 | | - priv->firm[n].ptr = kzalloc(size, GFP_KERNEL); |
---|
| 815 | + priv->firm[n].ptr = kmemdup(p, size, GFP_KERNEL); |
---|
825 | 816 | if (priv->firm[n].ptr == NULL) { |
---|
826 | 817 | printk(KERN_ERR "Not enough memory to load firmware file.\n"); |
---|
827 | 818 | rc = -ENOMEM; |
---|
.. | .. |
---|
835 | 826 | type, (unsigned long long)id, size); |
---|
836 | 827 | } |
---|
837 | 828 | |
---|
838 | | - memcpy(priv->firm[n].ptr, p, size); |
---|
839 | 829 | priv->firm[n].type = type; |
---|
840 | 830 | priv->firm[n].id = id; |
---|
841 | 831 | priv->firm[n].size = size; |
---|
.. | .. |
---|
1471 | 1461 | if (rc < 0) |
---|
1472 | 1462 | goto ret; |
---|
1473 | 1463 | |
---|
1474 | | - /* Informations from real testing of DVB-T and radio part, |
---|
1475 | | - coeficient for one dB is 0xff. |
---|
| 1464 | + /* Information from real testing of DVB-T and radio part, |
---|
| 1465 | + coefficient for one dB is 0xff. |
---|
1476 | 1466 | */ |
---|
1477 | 1467 | tuner_dbg("Signal strength: -%ddB (%05d)\n", value >> 8, value); |
---|
1478 | 1468 | |
---|
.. | .. |
---|
1754 | 1744 | xc4000_release(fe); |
---|
1755 | 1745 | return NULL; |
---|
1756 | 1746 | } |
---|
1757 | | -EXPORT_SYMBOL(xc4000_attach); |
---|
| 1747 | +EXPORT_SYMBOL_GPL(xc4000_attach); |
---|
1758 | 1748 | |
---|
1759 | 1749 | MODULE_AUTHOR("Steven Toth, Davide Ferri"); |
---|
1760 | 1750 | MODULE_DESCRIPTION("Xceive xc4000 silicon tuner driver"); |
---|