The following issues were found
arch/sparc/kernel/leon_pci_grpci1.c
1 issues
Line: 88
Column: 11
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 device *dev;
int pci_err_mask; /* STATUS register error mask */
int irq; /* LEON irqctrl GRPCI IRQ */
unsigned char irq_map[4]; /* GRPCI nexus PCI INTX# IRQs */
unsigned int irq_err; /* GRPCI nexus Virt Error IRQ */
/* AHB PCI Windows */
unsigned long pci_area; /* MEMORY */
unsigned long pci_area_end;
Reported by FlawFinder.
arch/x86/xen/efi.c
1 issues
Line: 139
Column: 2
CWE codes:
120
if (efi_systab_xen == NULL)
return;
strncpy((char *)&boot_params->efi_info.efi_loader_signature, "Xen",
sizeof(boot_params->efi_info.efi_loader_signature));
boot_params->efi_info.efi_systab = (__u32)__pa(efi_systab_xen);
boot_params->efi_info.efi_systab_hi = (__u32)(__pa(efi_systab_xen) >> 32);
boot_params->secure_boot = xen_efi_get_secureboot();
Reported by FlawFinder.
arch/sparc/kernel/module.c
1 issues
Line: 72
Column: 12
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
}
}
sym = (Elf_Sym *)sechdrs[symidx].sh_addr;
strtab = (char *)sechdrs[sechdrs[symidx].sh_link].sh_addr;
for (i = 1; i < sechdrs[symidx].sh_size / sizeof(Elf_Sym); i++) {
if (sym[i].st_shndx == SHN_UNDEF) {
if (ELF_ST_TYPE(sym[i].st_info) == STT_REGISTER)
sym[i].st_shndx = SHN_ABS;
Reported by FlawFinder.
arch/mips/include/asm/mach-cavium-octeon/kernel-entry-init.h
1 issues
Line: 37
Column: 31
CWE codes:
120
Suggestion:
Make sure destination can always hold the source data
dmtc0 v0, CP0_CVMMEMCTL_REG # Write the cavium mem control register
dmfc0 v0, CP0_CVMCTL_REG # Read the cavium control register
# Disable unaligned load/store support but leave HW fixup enabled
# Needed for octeon specific memcpy
or v0, v0, 0x5001
xor v0, v0, 0x1001
# First clear off CvmCtl[IPPCI] bit and move the performance
# counters interrupt to IRQ 6
dli v1, ~(7 << 7)
Reported by FlawFinder.
arch/mips/include/asm/mach-au1x00/au1xxx_eth.h
1 issues
Line: 13
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 phy_addr;
int phy_busid;
int phy_irq;
char mac[6];
};
void __init au1xxx_override_eth_cfg(unsigned port,
struct au1000_eth_platform_data *eth_data);
Reported by FlawFinder.
arch/mips/include/asm/mach-ath25/ath25_platform.h
1 issues
Line: 19
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 cksum; /* checksum (starting with BD_REV 2) */
u16 rev; /* revision of this struct */
#define BD_REV 4
char board_name[64]; /* Name of board */
u16 major; /* Board major number */
u16 minor; /* Board minor number */
u32 flags; /* Board configuration */
#define BD_ENET0 0x00000001 /* ENET0 is stuffed */
#define BD_ENET1 0x00000002 /* ENET1 is stuffed */
Reported by FlawFinder.
arch/mips/include/asm/mach-ar7/ar7.h
1 issues
Line: 99
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 reset_bit;
int power_bit;
u32 phy_mask;
char dev_addr[6];
};
struct plat_dsl_data {
int reset_bit_dsl;
int reset_bit_sar;
Reported by FlawFinder.
arch/sparc/kernel/pci_schizo.c
1 issues
Line: 622
Column: 16
CWE codes:
120
20
pbm->name);
ret = IRQ_HANDLED;
}
pbm->pci_ops->read(pbm->pci_bus, 0, PCI_STATUS, 2, &stat);
if (stat & (PCI_STATUS_PARITY |
PCI_STATUS_SIG_TARGET_ABORT |
PCI_STATUS_REC_TARGET_ABORT |
PCI_STATUS_REC_MASTER_ABORT |
PCI_STATUS_SIG_SYSTEM_ERROR)) {
Reported by FlawFinder.
arch/mips/include/asm/kexec.h
1 issues
Line: 29
Column: 3
CWE codes:
120
Suggestion:
Make sure destination can always hold the source data
struct pt_regs *oldregs)
{
if (oldregs)
memcpy(newregs, oldregs, sizeof(*newregs));
else
prepare_frametrace(newregs);
}
#ifdef CONFIG_KEXEC
Reported by FlawFinder.
arch/sparc/kernel/process_32.c
1 issues
Line: 315
Column: 2
CWE codes:
120
Suggestion:
Make sure destination can always hold the source data
ti->kwim = 1 << (((psr & PSR_CWP) + 1) % nwindows);
return 0;
}
memcpy(new_stack, (char *)regs - STACKFRAME_SZ, STACKFRAME_SZ + TRACEREG_SZ);
childregs->u_regs[UREG_FP] = sp;
p->thread.current_ds = USER_DS;
ti->kpc = (((unsigned long) ret_from_fork) - 0x8);
ti->kpsr = current->thread.fork_kpsr | PSR_PIL;
ti->kwim = current->thread.fork_kwim;
Reported by FlawFinder.