.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
---|
1 | 2 | /* |
---|
2 | 3 | Functions to query card hardware |
---|
3 | 4 | Copyright (C) 2003-2004 Kevin Thayer <nufan_wfk at yahoo.com> |
---|
4 | 5 | Copyright (C) 2005-2007 Hans Verkuil <hverkuil@xs4all.nl> |
---|
5 | 6 | |
---|
6 | | - This program is free software; you can redistribute it and/or modify |
---|
7 | | - it under the terms of the GNU General Public License as published by |
---|
8 | | - the Free Software Foundation; either version 2 of the License, or |
---|
9 | | - (at your option) any later version. |
---|
10 | | - |
---|
11 | | - This program is distributed in the hope that it will be useful, |
---|
12 | | - but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | | - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
14 | | - GNU General Public License for more details. |
---|
15 | | - |
---|
16 | | - You should have received a copy of the GNU General Public License |
---|
17 | | - along with this program; if not, write to the Free Software |
---|
18 | | - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
---|
19 | 7 | */ |
---|
20 | 8 | |
---|
21 | 9 | #include "ivtv-driver.h" |
---|
.. | .. |
---|
65 | 53 | |
---|
66 | 54 | /********************** card configuration *******************************/ |
---|
67 | 55 | |
---|
68 | | -/* Please add new PCI IDs to: http://pci-ids.ucw.cz/ |
---|
| 56 | +/* Please add new PCI IDs to: https://pci-ids.ucw.cz/ |
---|
69 | 57 | This keeps the PCI ID database up to date. Note that the entries |
---|
70 | 58 | must be added under vendor 0x4444 (Conexant) as subsystem IDs. |
---|
71 | 59 | New vendor IDs should still be added to the vendor ID list. */ |
---|
.. | .. |
---|
1317 | 1305 | if (index >= itv->nof_inputs) |
---|
1318 | 1306 | return -EINVAL; |
---|
1319 | 1307 | input->index = index; |
---|
1320 | | - strlcpy(input->name, input_strs[card_input->video_type - 1], |
---|
1321 | | - sizeof(input->name)); |
---|
| 1308 | + strscpy(input->name, input_strs[card_input->video_type - 1], |
---|
| 1309 | + sizeof(input->name)); |
---|
1322 | 1310 | input->type = (card_input->video_type == IVTV_CARD_INPUT_VID_TUNER ? |
---|
1323 | 1311 | V4L2_INPUT_TYPE_TUNER : V4L2_INPUT_TYPE_CAMERA); |
---|
1324 | 1312 | input->audioset = (1 << itv->nof_audio_inputs) - 1; |
---|
.. | .. |
---|
1334 | 1322 | if (index >= itv->card->nof_outputs) |
---|
1335 | 1323 | return -EINVAL; |
---|
1336 | 1324 | output->index = index; |
---|
1337 | | - strlcpy(output->name, card_output->name, sizeof(output->name)); |
---|
| 1325 | + strscpy(output->name, card_output->name, sizeof(output->name)); |
---|
1338 | 1326 | output->type = V4L2_OUTPUT_TYPE_ANALOG; |
---|
1339 | 1327 | output->audioset = 1; |
---|
1340 | 1328 | output->std = V4L2_STD_ALL; |
---|
.. | .. |
---|
1353 | 1341 | memset(audio, 0, sizeof(*audio)); |
---|
1354 | 1342 | if (index >= itv->nof_audio_inputs) |
---|
1355 | 1343 | return -EINVAL; |
---|
1356 | | - strlcpy(audio->name, input_strs[aud_input->audio_type - 1], |
---|
1357 | | - sizeof(audio->name)); |
---|
| 1344 | + strscpy(audio->name, input_strs[aud_input->audio_type - 1], |
---|
| 1345 | + sizeof(audio->name)); |
---|
1358 | 1346 | audio->index = index; |
---|
1359 | 1347 | audio->capability = V4L2_AUDCAP_STEREO; |
---|
1360 | 1348 | return 0; |
---|
.. | .. |
---|
1365 | 1353 | memset(aud_output, 0, sizeof(*aud_output)); |
---|
1366 | 1354 | if (itv->card->video_outputs == NULL || index != 0) |
---|
1367 | 1355 | return -EINVAL; |
---|
1368 | | - strlcpy(aud_output->name, "A/V Audio Out", sizeof(aud_output->name)); |
---|
| 1356 | + strscpy(aud_output->name, "A/V Audio Out", sizeof(aud_output->name)); |
---|
1369 | 1357 | return 0; |
---|
1370 | 1358 | } |
---|