The following issues were found

drivers/dma/dw-edma/dw-edma-core.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 117 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

              };

struct dw_edma {
	char				name[20];

	struct dma_device		wr_edma;
	u16				wr_ch_cnt;

	struct dma_device		rd_edma;

            

Reported by FlawFinder.

drivers/dma/dw-edma/dw-edma-pcie.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

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

              		return err;
	}

	memcpy(&vsec_data, pdata, sizeof(struct dw_edma_pcie_data));

	/*
	 * Tries to find if exists a PCIe Vendor-Specific Extended Capability
	 * for the DMA, if one exists, then reconfigures it.
	 */

            

Reported by FlawFinder.

drivers/dma/dw/regs.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 315 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

              
struct dw_dma {
	struct dma_device	dma;
	char			name[20];
	void __iomem		*regs;
	struct dma_pool		*desc_pool;
	struct tasklet_struct	tasklet;

	/* channels */

            

Reported by FlawFinder.

drivers/dma/ep93xx_dma.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

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

              {
	struct ep93xx_dma_chan *edmac = to_ep93xx_dma_chan(chan);

	memcpy(&edmac->slave_config, config, sizeof(*config));

	return 0;
}

static int ep93xx_dma_slave_config_write(struct dma_chan *chan,

            

Reported by FlawFinder.

drivers/dma/fsl-edma-common.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

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

              {
	struct fsl_edma_chan *fsl_chan = to_fsl_edma_chan(chan);

	memcpy(&fsl_chan->cfg, cfg, sizeof(*cfg));
	fsl_edma_unprep_slave_dma(fsl_chan);

	return 0;
}
EXPORT_SYMBOL_GPL(fsl_edma_slave_config);

            

Reported by FlawFinder.

drivers/dma/fsl-edma-common.h
1 issues
char - Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues
Security

Line: 128 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

              	dma_addr_t			dma_dev_addr;
	u32				dma_dev_size;
	enum dma_data_direction		dma_dir;
	char				chan_name[16];
};

struct fsl_edma_desc {
	struct virt_dma_desc		vdesc;
	struct fsl_edma_chan		*echan;

            

Reported by FlawFinder.

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

Line: 267 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

              
/* Per job ring data structure */
struct fsl_re_chan {
	char name[16];
	spinlock_t desc_lock; /* queue lock */
	struct list_head ack_q;  /* wait to acked queue */
	struct list_head active_q; /* already issued on hw, not completed */
	struct list_head submit_q;
	struct list_head free_q; /* alloc available queue */

            

Reported by FlawFinder.

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

Line: 152 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

              #endif

struct fsldma_chan {
	char name[8];			/* Channel name */
	struct fsldma_chan_regs __iomem *regs;
	spinlock_t desc_lock;		/* Descriptor operation lock */
	/*
	 * Descriptors which are queued to run, but have not yet been
	 * submitted to the hardware for execution

            

Reported by FlawFinder.

drivers/dma/hisi_dma.c
1 issues
memcpy - Does not check for buffer overflows when copying to destination
Security

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

              	desc = to_hisi_dma_desc(vd);
	chan->desc = desc;

	memcpy(sqe, &desc->sqe, sizeof(struct hisi_dma_sqe));

	/* update other field in sqe */
	sqe->dw0 = cpu_to_le32(FIELD_PREP(OPCODE_MASK, OPCODE_M2M));
	sqe->dw0 |= cpu_to_le32(LOCAL_IRQ_EN);


            

Reported by FlawFinder.

drivers/dma/idxd/perfmon.h
1 issues
sprintf - Potential format string problem
Security

Line: 114 Column: 9 CWE codes: 134
Suggestion: Make format string constant

              				char *page)				\
{									\
	BUILD_BUG_ON(sizeof(_format) >= PAGE_SIZE);			\
	return sprintf(page, _format "\n");				\
}									\
static struct kobj_attribute format_attr_idxd_##_name =			\
	__ATTR(_name, 0444, __perfmon_idxd_##_name##_show, NULL)

#endif

            

Reported by FlawFinder.