The following issues were found

drivers/media/pci/tw5864/tw5864-video.c
1 issues
sprintf - Does not check for buffer overflows
Security

Line: 607 Column: 2 CWE codes: 120
Suggestion: Use sprintf_s, snprintf, or vsnprintf

              	strscpy(cap->driver, "tw5864", sizeof(cap->driver));
	snprintf(cap->card, sizeof(cap->card), "TW5864 Encoder %d",
		 input->nr);
	sprintf(cap->bus_info, "PCI:%s", pci_name(input->root->pci));
	return 0;
}

static int tw5864_querystd(struct file *file, void *priv, v4l2_std_id *std)
{

            

Reported by FlawFinder.

drivers/media/pci/sta2x11/sta2x11_vip.c
1 issues
sprintf - Does not check for buffer overflows
Security

Line: 495 Column: 2 CWE codes: 120
Suggestion: Use sprintf_s, snprintf, or vsnprintf

              
	inp->type = V4L2_INPUT_TYPE_CAMERA;
	inp->std = V4L2_STD_ALL;
	sprintf(inp->name, "Camera %u", inp->index);

	return 0;
}

/**

            

Reported by FlawFinder.

drivers/media/pci/solo6x10/solo6x10.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 158 Column: 2 CWE codes: 119 120
Suggestion: Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length

              	u16			height;

	/* OSD buffers */
	char			osd_text[OSD_TEXT_MAX + 1];
	u8			osd_buf[SOLO_EOSD_EXT_SIZE_MAX]
					__aligned(4);

	/* VOP stuff */
	u8			vop[64];

            

Reported by FlawFinder.

drivers/misc/habanalabs/include/common/cpucp_if.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 688 Column: 2 CWE codes: 119 120
Suggestion: Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length

              	__u8 cpucp_version[VERSION_MAX_LEN];
	__le32 reserved2;
	__le64 dram_size;
	char card_name[CARD_NAME_MAX_LEN];
	__le64 reserved3;
	__le64 reserved4;
	__u8 reserved5;
	__u8 pad[7];
	struct cpucp_security_info sec_info;

            

Reported by FlawFinder.

drivers/media/pci/smipcie/smipcie-main.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

Line: 716 Column: 2 CWE codes: 120
Suggestion: Make sure destination can always hold the source data

              	dev_info(&port->dev->pci_dev->dev,
		"%s port %d MAC: %pM\n", dev->info->name,
		port->idx, mac_ee + (port->idx)*8);
	memcpy(adap->proposed_mac, mac_ee + (port->idx)*8, 6);
	return ret;
}

static void smi_fe_exit(struct smi_port *port)
{

            

Reported by FlawFinder.

drivers/misc/habanalabs/include/gaudi/gaudi_async_ids_map_extended.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 20 Column: 2 CWE codes: 119 120
Suggestion: Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length

              	int fc_id;
	int cpu_id;
	int valid;
	char name[64];
};

static struct gaudi_async_events_ids_map gaudi_irq_map_table[] = {
	{ .fc_id = 0, .cpu_id = 0, .valid = 0, .name = "" },
	{ .fc_id = 1, .cpu_id = 1, .valid = 0, .name = "" },

            

Reported by FlawFinder.

drivers/misc/hpilo.c
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 31 Column: 8 CWE codes: 119 120
Suggestion: Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length

              static struct class *ilo_class;
static unsigned int ilo_major;
static unsigned int max_ccb = 16;
static char ilo_hwdev[MAX_ILO_DEV];
static const struct pci_device_id ilo_blacklist[] = {
	/* auxiliary iLO */
	{PCI_DEVICE_SUB(PCI_VENDOR_ID_HP, 0x3307, PCI_VENDOR_ID_HP, 0x1979)},
	/* CL */
	{PCI_DEVICE_SUB(PCI_VENDOR_ID_HP, 0x3307, PCI_VENDOR_ID_HP_3PAR, 0x0289)},

            

Reported by FlawFinder.

drivers/misc/ibmasm/event.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

Line: 101 Column: 2 CWE codes: 120
Suggestion: Make sure destination can always hold the source data

              		index = (index + 1) % IBMASM_NUM_EVENTS;
		event = &buffer->events[index];
	}
	memcpy(reader->data, event->data, event->data_size);
	reader->data_size = event->data_size;
	reader->next_serial_number = event->serial_number + 1;

	spin_unlock_irqrestore(&sp->lock, flags);


            

Reported by FlawFinder.

drivers/media/pci/saa7164/saa7164-vbi.c
1 issues
sprintf - Does not check for buffer overflows
Security

Line: 204 Column: 2 CWE codes: 120
Suggestion: Use sprintf_s, snprintf, or vsnprintf

              	strscpy(cap->driver, dev->name, sizeof(cap->driver));
	strscpy(cap->card, saa7164_boards[dev->board].name,
		sizeof(cap->card));
	sprintf(cap->bus_info, "PCI:%s", pci_name(dev->pci));
	cap->capabilities = V4L2_CAP_VIDEO_CAPTURE | V4L2_CAP_READWRITE |
			    V4L2_CAP_TUNER | V4L2_CAP_VBI_CAPTURE |
			    V4L2_CAP_DEVICE_CAPS;
	return 0;
}

            

Reported by FlawFinder.

drivers/misc/ibmasm/ibmasmfs.c
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 507 Column: 2 CWE codes: 119 120
Suggestion: Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length

              	void __iomem *address = (void __iomem *)file->private_data;
	int len = 0;
	unsigned int value;
	char lbuf[20];

	value = readl(address);
	len = snprintf(lbuf, sizeof(lbuf), "%d\n", value);

	return simple_read_from_buffer(buf, count, offset, lbuf, len);

            

Reported by FlawFinder.