Exploit databaseDownload repository ZIP
GH-b6f78b211ff4ea5e7b3ebffe1f088758
abrarkhan/linux-4.19.72_cve-2020-24490
Sources for CVE-2020-24490
5 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files49
abrarkhan/linux-4.19.72_cve-2020-24490Revision aa3f6929b62b
- ↑..Parent directory
- Kconfig
- Makefile
- cx18-alsa-main.c
- cx18-alsa-pcm.c
- cx18-alsa-pcm.h
- cx18-alsa.h
- cx18-audio.c
- cx18-audio.h
- cx18-av-audio.c
- cx18-av-core.c
- cx18-av-core.h
- cx18-av-firmware.c
- cx18-av-vbi.c
- cx18-cards.c
- cx18-cards.h
- cx18-controls.c
- cx18-controls.h
- cx18-driver.c
- cx18-driver.h
- cx18-dvb.c
- cx18-dvb.h
- cx18-fileops.c
- cx18-fileops.h
- cx18-firmware.c
- cx18-firmware.h
- cx18-gpio.c
- cx18-gpio.h
- cx18-i2c.c
- cx18-i2c.h
- cx18-io.c
- cx18-io.h
- cx18-ioctl.c
- cx18-ioctl.h
- cx18-irq.c
- cx18-irq.h
- cx18-mailbox.c
- cx18-mailbox.h
- cx18-queue.c
- cx18-queue.h
- cx18-scb.c
- cx18-scb.h
- cx18-streams.c
- cx18-streams.h
- cx18-vbi.c
- cx18-vbi.h
- cx18-version.h
- cx18-video.c
- cx18-video.h
- cx23418.h
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
drivers/media/pci/cx18/cx18-irq.c
C · 2,104 bytes/*
* cx18 interrupt handling
*
* Copyright (C) 2007 Hans Verkuil <[email protected]>
* Copyright (C) 2008 Andy Walls <[email protected]>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*/
#include "cx18-driver.h"
#include "cx18-io.h"
#include "cx18-irq.h"
#include "cx18-mailbox.h"
#include "cx18-scb.h"
static void xpu_ack(struct cx18 *cx, u32 sw2)
{
if (sw2 & IRQ_CPU_TO_EPU_ACK)
wake_up(&cx->mb_cpu_waitq);
if (sw2 & IRQ_APU_TO_EPU_ACK)
wake_up(&cx->mb_apu_waitq);
}
static void epu_cmd(struct cx18 *cx, u32 sw1)
{
if (sw1 & IRQ_CPU_TO_EPU)
cx18_api_epu_cmd_irq(cx, CPU);
if (sw1 & IRQ_APU_TO_EPU)
cx18_api_epu_cmd_irq(cx, APU);
}
irqreturn_t cx18_irq_handler(int irq, void *dev_id)
{
struct cx18 *cx = (struct cx18 *)dev_id;
u32 sw1, sw2, hw2;
sw1 = cx18_read_reg(cx, SW1_INT_STATUS) & cx->sw1_irq_mask;
sw2 = cx18_read_reg(cx, SW2_INT_STATUS) & cx->sw2_irq_mask;
hw2 = cx18_read_reg(cx, HW2_INT_CLR_STATUS) & cx->hw2_irq_mask;
if (sw1)
cx18_write_reg_expect(cx, sw1, SW1_INT_STATUS, ~sw1, sw1);
if (sw2)
cx18_write_reg_expect(cx, sw2, SW2_INT_STATUS, ~sw2, sw2);
if (hw2)
cx18_write_reg_expect(cx, hw2, HW2_INT_CLR_STATUS, ~hw2, hw2);
if (sw1 || sw2 || hw2)
CX18_DEBUG_HI_IRQ("received interrupts SW1: %x SW2: %x HW2: %x\n",
sw1, sw2, hw2);
/*
* SW1 responses have to happen first. The sending XPU times out the
* incoming mailboxes on us rather rapidly.
*/
if (sw1)
epu_cmd(cx, sw1);
/* To do: interrupt-based I2C handling
if (hw2 & (HW2_I2C1_INT|HW2_I2C2_INT)) {
}
*/
if (sw2)
xpu_ack(cx, sw2);
return (sw1 || sw2 || hw2) ? IRQ_HANDLED : IRQ_NONE;
}