Commit 3e9442c6 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

V4L/DVB: cx25821: Fix bad whitespacing

Should use tabs for identation, and not whitespace
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent e986bf1e
cx25821-objs := cx25821-core.o cx25821-cards.o cx25821-i2c.o \ cx25821-objs := cx25821-core.o cx25821-cards.o cx25821-i2c.o \
cx25821-gpio.o cx25821-medusa-video.o \ cx25821-gpio.o cx25821-medusa-video.o \
cx25821-video.o cx25821-video-upstream.o \ cx25821-video.o cx25821-video-upstream.o \
cx25821-video-upstream-ch2.o \ cx25821-video-upstream-ch2.o \
cx25821-audio-upstream.o cx25821-audio-upstream.o
obj-$(CONFIG_VIDEO_CX25821) += cx25821.o obj-$(CONFIG_VIDEO_CX25821) += cx25821.o
obj-$(CONFIG_VIDEO_CX25821_ALSA) += cx25821-alsa.o obj-$(CONFIG_VIDEO_CX25821_ALSA) += cx25821-alsa.o
......
...@@ -106,7 +106,7 @@ static __le32 *cx25821_risc_field_upstream_audio(struct cx25821_dev *dev, ...@@ -106,7 +106,7 @@ static __le32 *cx25821_risc_field_upstream_audio(struct cx25821_dev *dev,
{ {
unsigned int line; unsigned int line;
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[dev->_audio_upstream_channel_select].sram_channels; dev->channels[dev->_audio_upstream_channel_select].sram_channels;
int offset = 0; int offset = 0;
/* scan lines */ /* scan lines */
...@@ -217,7 +217,7 @@ void cx25821_free_memory_audio(struct cx25821_dev *dev) ...@@ -217,7 +217,7 @@ void cx25821_free_memory_audio(struct cx25821_dev *dev)
void cx25821_stop_upstream_audio(struct cx25821_dev *dev) void cx25821_stop_upstream_audio(struct cx25821_dev *dev)
{ {
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[AUDIO_UPSTREAM_SRAM_CHANNEL_B].sram_channels; dev->channels[AUDIO_UPSTREAM_SRAM_CHANNEL_B].sram_channels;
u32 tmp = 0; u32 tmp = 0;
if (!dev->_audio_is_running) { if (!dev->_audio_is_running) {
...@@ -353,9 +353,9 @@ static void cx25821_audioups_handler(struct work_struct *work) ...@@ -353,9 +353,9 @@ static void cx25821_audioups_handler(struct work_struct *work)
} }
cx25821_get_audio_data(dev, cx25821_get_audio_data(dev,
dev->channels[dev-> dev->channels[dev->
_audio_upstream_channel_select]. _audio_upstream_channel_select].
sram_channels); sram_channels);
} }
int cx25821_openfile_audio(struct cx25821_dev *dev, int cx25821_openfile_audio(struct cx25821_dev *dev,
...@@ -609,7 +609,7 @@ static irqreturn_t cx25821_upstream_irq_audio(int irq, void *dev_id) ...@@ -609,7 +609,7 @@ static irqreturn_t cx25821_upstream_irq_audio(int irq, void *dev_id)
return -1; return -1;
sram_ch = dev->channels[dev->_audio_upstream_channel_select]. sram_ch = dev->channels[dev->_audio_upstream_channel_select].
sram_channels; sram_channels;
msk_stat = cx_read(sram_ch->int_mstat); msk_stat = cx_read(sram_ch->int_mstat);
audio_status = cx_read(sram_ch->int_stat); audio_status = cx_read(sram_ch->int_stat);
......
...@@ -781,14 +781,14 @@ static void cx25821_shutdown(struct cx25821_dev *dev) ...@@ -781,14 +781,14 @@ static void cx25821_shutdown(struct cx25821_dev *dev)
/* Disable Video A/B activity */ /* Disable Video A/B activity */
for (i = 0; i < VID_CHANNEL_NUM; i++) { for (i = 0; i < VID_CHANNEL_NUM; i++) {
cx_write(dev->channels[i].sram_channels->dma_ctl, 0); cx_write(dev->channels[i].sram_channels->dma_ctl, 0);
cx_write(dev->channels[i].sram_channels->int_msk, 0); cx_write(dev->channels[i].sram_channels->int_msk, 0);
} }
for (i = VID_UPSTREAM_SRAM_CHANNEL_I; i <= VID_UPSTREAM_SRAM_CHANNEL_J; for (i = VID_UPSTREAM_SRAM_CHANNEL_I; i <= VID_UPSTREAM_SRAM_CHANNEL_J;
i++) { i++) {
cx_write(dev->channels[i].sram_channels->dma_ctl, 0); cx_write(dev->channels[i].sram_channels->dma_ctl, 0);
cx_write(dev->channels[i].sram_channels->int_msk, 0); cx_write(dev->channels[i].sram_channels->int_msk, 0);
} }
/* Disable Audio activity */ /* Disable Audio activity */
...@@ -806,9 +806,9 @@ void cx25821_set_pixel_format(struct cx25821_dev *dev, int channel_select, ...@@ -806,9 +806,9 @@ void cx25821_set_pixel_format(struct cx25821_dev *dev, int channel_select,
u32 format) u32 format)
{ {
if (channel_select <= 7 && channel_select >= 0) { if (channel_select <= 7 && channel_select >= 0) {
cx_write(dev->channels[channel_select]. cx_write(dev->channels[channel_select].
sram_channels->pix_frmt, format); sram_channels->pix_frmt, format);
dev->channels[channel_select].pixel_formats = format; dev->channels[channel_select].pixel_formats = format;
} }
} }
...@@ -829,7 +829,7 @@ static void cx25821_initialize(struct cx25821_dev *dev) ...@@ -829,7 +829,7 @@ static void cx25821_initialize(struct cx25821_dev *dev)
cx_write(PCI_INT_STAT, 0xffffffff); cx_write(PCI_INT_STAT, 0xffffffff);
for (i = 0; i < VID_CHANNEL_NUM; i++) for (i = 0; i < VID_CHANNEL_NUM; i++)
cx_write(dev->channels[i].sram_channels->int_stat, 0xffffffff); cx_write(dev->channels[i].sram_channels->int_stat, 0xffffffff);
cx_write(AUD_A_INT_STAT, 0xffffffff); cx_write(AUD_A_INT_STAT, 0xffffffff);
cx_write(AUD_B_INT_STAT, 0xffffffff); cx_write(AUD_B_INT_STAT, 0xffffffff);
...@@ -843,22 +843,22 @@ static void cx25821_initialize(struct cx25821_dev *dev) ...@@ -843,22 +843,22 @@ static void cx25821_initialize(struct cx25821_dev *dev)
mdelay(100); mdelay(100);
for (i = 0; i < VID_CHANNEL_NUM; i++) { for (i = 0; i < VID_CHANNEL_NUM; i++) {
cx25821_set_vip_mode(dev, dev->channels[i].sram_channels); cx25821_set_vip_mode(dev, dev->channels[i].sram_channels);
cx25821_sram_channel_setup(dev, dev->channels[i].sram_channels, cx25821_sram_channel_setup(dev, dev->channels[i].sram_channels,
1440, 0); 1440, 0);
dev->channels[i].pixel_formats = PIXEL_FRMT_422; dev->channels[i].pixel_formats = PIXEL_FRMT_422;
dev->channels[i].use_cif_resolution = FALSE; dev->channels[i].use_cif_resolution = FALSE;
} }
/* Probably only affect Downstream */ /* Probably only affect Downstream */
for (i = VID_UPSTREAM_SRAM_CHANNEL_I; i <= VID_UPSTREAM_SRAM_CHANNEL_J; for (i = VID_UPSTREAM_SRAM_CHANNEL_I; i <= VID_UPSTREAM_SRAM_CHANNEL_J;
i++) { i++) {
cx25821_set_vip_mode(dev, dev->channels[i].sram_channels); cx25821_set_vip_mode(dev, dev->channels[i].sram_channels);
} }
cx25821_sram_channel_setup_audio(dev, cx25821_sram_channel_setup_audio(dev,
dev->channels[SRAM_CH08].sram_channels, dev->channels[SRAM_CH08].sram_channels,
128, 0); 128, 0);
cx25821_gpio_init(dev); cx25821_gpio_init(dev);
} }
...@@ -932,7 +932,7 @@ static int cx25821_dev_setup(struct cx25821_dev *dev) ...@@ -932,7 +932,7 @@ static int cx25821_dev_setup(struct cx25821_dev *dev)
/* Apply a sensible clock frequency for the PCIe bridge */ /* Apply a sensible clock frequency for the PCIe bridge */
dev->clk_freq = 28000000; dev->clk_freq = 28000000;
for (i = 0; i < MAX_VID_CHANNEL_NUM; i++) for (i = 0; i < MAX_VID_CHANNEL_NUM; i++)
dev->channels[i].sram_channels = &cx25821_sram_channels[i]; dev->channels[i].sram_channels = &cx25821_sram_channels[i];
if (dev->nr > 1) if (dev->nr > 1)
CX25821_INFO("dev->nr > 1!"); CX25821_INFO("dev->nr > 1!");
...@@ -1004,22 +1004,22 @@ static int cx25821_dev_setup(struct cx25821_dev *dev) ...@@ -1004,22 +1004,22 @@ static int cx25821_dev_setup(struct cx25821_dev *dev)
cx25821_card_setup(dev); cx25821_card_setup(dev);
if (medusa_video_init(dev) < 0) if (medusa_video_init(dev) < 0)
CX25821_ERR("%s() Failed to initialize medusa!\n" CX25821_ERR("%s() Failed to initialize medusa!\n"
, __func__); , __func__);
cx25821_video_register(dev); cx25821_video_register(dev);
/* register IOCTL device */ /* register IOCTL device */
dev->ioctl_dev = dev->ioctl_dev =
cx25821_vdev_init(dev, dev->pci, &cx25821_videoioctl_template, cx25821_vdev_init(dev, dev->pci, &cx25821_videoioctl_template,
"video"); "video");
if (video_register_device if (video_register_device
(dev->ioctl_dev, VFL_TYPE_GRABBER, VIDEO_IOCTL_CH) < 0) { (dev->ioctl_dev, VFL_TYPE_GRABBER, VIDEO_IOCTL_CH) < 0) {
cx25821_videoioctl_unregister(dev); cx25821_videoioctl_unregister(dev);
printk(KERN_ERR printk(KERN_ERR
"%s() Failed to register video adapter for IOCTL, so \ "%s() Failed to register video adapter for IOCTL, so \
unregistering videoioctl device.\n", __func__); unregistering videoioctl device.\n", __func__);
} }
cx25821_dev_checkrevision(dev); cx25821_dev_checkrevision(dev);
...@@ -1342,8 +1342,8 @@ static irqreturn_t cx25821_irq(int irq, void *dev_id) ...@@ -1342,8 +1342,8 @@ static irqreturn_t cx25821_irq(int irq, void *dev_id)
for (i = 0; i < VID_CHANNEL_NUM; i++) { for (i = 0; i < VID_CHANNEL_NUM; i++) {
if (pci_status & mask[i]) { if (pci_status & mask[i]) {
vid_status = cx_read(dev->channels[i]. vid_status = cx_read(dev->channels[i].
sram_channels->int_stat); sram_channels->int_stat);
if (vid_status) if (vid_status)
handled += handled +=
......
...@@ -830,8 +830,8 @@ int medusa_video_init(struct cx25821_dev *dev) ...@@ -830,8 +830,8 @@ int medusa_video_init(struct cx25821_dev *dev)
value = cx25821_i2c_read(&dev->i2c_bus[0], AFE_AB_DIAG_CTRL, &tmp); value = cx25821_i2c_read(&dev->i2c_bus[0], AFE_AB_DIAG_CTRL, &tmp);
value &= 0x83FFFFFF; value &= 0x83FFFFFF;
ret_val = ret_val =
cx25821_i2c_write(&dev->i2c_bus[0], AFE_AB_DIAG_CTRL, cx25821_i2c_write(&dev->i2c_bus[0], AFE_AB_DIAG_CTRL,
value | 0x10000000); value | 0x10000000);
if (ret_val < 0) if (ret_val < 0)
goto error; goto error;
......
...@@ -84,7 +84,7 @@ static __le32 *cx25821_risc_field_upstream_ch2(struct cx25821_dev *dev, ...@@ -84,7 +84,7 @@ static __le32 *cx25821_risc_field_upstream_ch2(struct cx25821_dev *dev,
{ {
unsigned int line, i; unsigned int line, i;
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[dev->_channel2_upstream_select].sram_channels; dev->channels[dev->_channel2_upstream_select].sram_channels;
int dist_betwn_starts = bpl * 2; int dist_betwn_starts = bpl * 2;
/* sync instruction */ /* sync instruction */
...@@ -110,11 +110,11 @@ static __le32 *cx25821_risc_field_upstream_ch2(struct cx25821_dev *dev, ...@@ -110,11 +110,11 @@ static __le32 *cx25821_risc_field_upstream_ch2(struct cx25821_dev *dev,
offset += dist_betwn_starts; offset += dist_betwn_starts;
} }
/* /*
check if we need to enable the FIFO after the first 4 lines check if we need to enable the FIFO after the first 4 lines
For the upstream video channel, the risc engine will enable For the upstream video channel, the risc engine will enable
the FIFO. the FIFO.
*/ */
if (fifo_enable && line == 3) { if (fifo_enable && line == 3) {
*(rp++) = RISC_WRITECR; *(rp++) = RISC_WRITECR;
*(rp++) = sram_ch->dma_ctl; *(rp++) = sram_ch->dma_ctl;
...@@ -177,7 +177,7 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev, ...@@ -177,7 +177,7 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev,
fifo_enable = FIFO_DISABLE; fifo_enable = FIFO_DISABLE;
/* Even field */ /* Even field */
rp = cx25821_risc_field_upstream_ch2(dev, rp, rp = cx25821_risc_field_upstream_ch2(dev, rp,
dev-> dev->
_data_buf_phys_addr_ch2 + _data_buf_phys_addr_ch2 +
...@@ -195,10 +195,10 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev, ...@@ -195,10 +195,10 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev,
risc_phys_jump_addr = dev->_dma_phys_start_addr_ch2; risc_phys_jump_addr = dev->_dma_phys_start_addr_ch2;
} }
/* /*
Loop to 2ndFrameRISC or to Start of Loop to 2ndFrameRISC or to Start of
Risc program & generate IRQ Risc program & generate IRQ
*/ */
*(rp++) = cpu_to_le32(RISC_JUMP | RISC_IRQ1 | risc_flag); *(rp++) = cpu_to_le32(RISC_JUMP | RISC_IRQ1 | risc_flag);
*(rp++) = cpu_to_le32(risc_phys_jump_addr); *(rp++) = cpu_to_le32(risc_phys_jump_addr);
*(rp++) = cpu_to_le32(0); *(rp++) = cpu_to_le32(0);
...@@ -210,7 +210,7 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev, ...@@ -210,7 +210,7 @@ int cx25821_risc_buffer_upstream_ch2(struct cx25821_dev *dev,
void cx25821_stop_upstream_video_ch2(struct cx25821_dev *dev) void cx25821_stop_upstream_video_ch2(struct cx25821_dev *dev)
{ {
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[VID_UPSTREAM_SRAM_CHANNEL_J].sram_channels; dev->channels[VID_UPSTREAM_SRAM_CHANNEL_J].sram_channels;
u32 tmp = 0; u32 tmp = 0;
if (!dev->_is_running_ch2) { if (!dev->_is_running_ch2) {
...@@ -377,8 +377,8 @@ static void cx25821_vidups_handler_ch2(struct work_struct *work) ...@@ -377,8 +377,8 @@ static void cx25821_vidups_handler_ch2(struct work_struct *work)
} }
cx25821_get_frame_ch2(dev, cx25821_get_frame_ch2(dev,
dev->channels[dev-> dev->channels[dev->
_channel2_upstream_select].sram_channels); _channel2_upstream_select].sram_channels);
} }
int cx25821_openfile_ch2(struct cx25821_dev *dev, struct sram_channel *sram_ch) int cx25821_openfile_ch2(struct cx25821_dev *dev, struct sram_channel *sram_ch)
...@@ -550,13 +550,13 @@ int cx25821_video_upstream_irq_ch2(struct cx25821_dev *dev, int chan_num, ...@@ -550,13 +550,13 @@ int cx25821_video_upstream_irq_ch2(struct cx25821_dev *dev, int chan_num,
__le32 *rp; __le32 *rp;
if (status & FLD_VID_SRC_RISC1) { if (status & FLD_VID_SRC_RISC1) {
/* We should only process one program per call */ /* We should only process one program per call */
u32 prog_cnt = cx_read(channel->gpcnt); u32 prog_cnt = cx_read(channel->gpcnt);
/* /*
Since we've identified our IRQ, clear our bits from the Since we've identified our IRQ, clear our bits from the
interrupt mask and interrupt status registers interrupt mask and interrupt status registers
*/ */
int_msk_tmp = cx_read(channel->int_msk); int_msk_tmp = cx_read(channel->int_msk);
cx_write(channel->int_msk, int_msk_tmp & ~_intr_msk); cx_write(channel->int_msk, int_msk_tmp & ~_intr_msk);
cx_write(channel->int_stat, _intr_msk); cx_write(channel->int_stat, _intr_msk);
...@@ -597,7 +597,7 @@ int cx25821_video_upstream_irq_ch2(struct cx25821_dev *dev, int chan_num, ...@@ -597,7 +597,7 @@ int cx25821_video_upstream_irq_ch2(struct cx25821_dev *dev, int chan_num,
FIFO_DISABLE, FIFO_DISABLE,
ODD_FIELD); ODD_FIELD);
/* Jump to Even Risc program of 1st Frame */ /* Jump to Even Risc program of 1st Frame */
*(rp++) = cpu_to_le32(RISC_JUMP); *(rp++) = cpu_to_le32(RISC_JUMP);
*(rp++) = cpu_to_le32(risc_phys_jump_addr); *(rp++) = cpu_to_le32(risc_phys_jump_addr);
*(rp++) = cpu_to_le32(0); *(rp++) = cpu_to_le32(0);
...@@ -668,8 +668,8 @@ static void cx25821_set_pixelengine_ch2(struct cx25821_dev *dev, ...@@ -668,8 +668,8 @@ static void cx25821_set_pixelengine_ch2(struct cx25821_dev *dev,
cx_write(ch->vid_fmt_ctl, value); cx_write(ch->vid_fmt_ctl, value);
/* /*
set number of active pixels in each line. Default is 720 set number of active pixels in each line. Default is 720
pixels in both NTSC and PAL format pixels in both NTSC and PAL format
*/ */
cx_write(ch->vid_active_ctl1, width); cx_write(ch->vid_active_ctl1, width);
...@@ -695,15 +695,15 @@ int cx25821_start_video_dma_upstream_ch2(struct cx25821_dev *dev, ...@@ -695,15 +695,15 @@ int cx25821_start_video_dma_upstream_ch2(struct cx25821_dev *dev,
int err = 0; int err = 0;
/* /*
656/VIP SRC Upstream Channel I & J and 7 - Host Bus Interface 656/VIP SRC Upstream Channel I & J and 7 - Host Bus Interface
for channel A-C for channel A-C
*/ */
tmp = cx_read(VID_CH_MODE_SEL); tmp = cx_read(VID_CH_MODE_SEL);
cx_write(VID_CH_MODE_SEL, tmp | 0x1B0001FF); cx_write(VID_CH_MODE_SEL, tmp | 0x1B0001FF);
/* /*
Set the physical start address of the RISC program in the initial Set the physical start address of the RISC program in the initial
program counter(IPC) member of the cmds. program counter(IPC) member of the cmds.
*/ */
cx_write(sram_ch->cmds_start + 0, dev->_dma_phys_addr_ch2); cx_write(sram_ch->cmds_start + 0, dev->_dma_phys_addr_ch2);
cx_write(sram_ch->cmds_start + 4, 0); /* Risc IPC High 64 bits 63-32 */ cx_write(sram_ch->cmds_start + 4, 0); /* Risc IPC High 64 bits 63-32 */
...@@ -770,8 +770,8 @@ int cx25821_vidupstream_init_ch2(struct cx25821_dev *dev, int channel_select, ...@@ -770,8 +770,8 @@ int cx25821_vidupstream_init_ch2(struct cx25821_dev *dev, int channel_select,
return -ENOMEM; return -ENOMEM;
} }
/* /*
656/VIP SRC Upstream Channel I & J and 7 - 656/VIP SRC Upstream Channel I & J and 7 -
Host Bus Interface for channel A-C Host Bus Interface for channel A-C
*/ */
tmp = cx_read(VID_CH_MODE_SEL); tmp = cx_read(VID_CH_MODE_SEL);
cx_write(VID_CH_MODE_SEL, tmp | 0x1B0001FF); cx_write(VID_CH_MODE_SEL, tmp | 0x1B0001FF);
......
...@@ -134,7 +134,7 @@ static __le32 *cx25821_risc_field_upstream(struct cx25821_dev *dev, __le32 * rp, ...@@ -134,7 +134,7 @@ static __le32 *cx25821_risc_field_upstream(struct cx25821_dev *dev, __le32 * rp,
{ {
unsigned int line, i; unsigned int line, i;
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[dev->_channel_upstream_select].sram_channels; dev->channels[dev->_channel_upstream_select].sram_channels;
int dist_betwn_starts = bpl * 2; int dist_betwn_starts = bpl * 2;
/* sync instruction */ /* sync instruction */
...@@ -253,7 +253,7 @@ int cx25821_risc_buffer_upstream(struct cx25821_dev *dev, ...@@ -253,7 +253,7 @@ int cx25821_risc_buffer_upstream(struct cx25821_dev *dev,
void cx25821_stop_upstream_video_ch1(struct cx25821_dev *dev) void cx25821_stop_upstream_video_ch1(struct cx25821_dev *dev)
{ {
struct sram_channel *sram_ch = struct sram_channel *sram_ch =
dev->channels[VID_UPSTREAM_SRAM_CHANNEL_I].sram_channels; dev->channels[VID_UPSTREAM_SRAM_CHANNEL_I].sram_channels;
u32 tmp = 0; u32 tmp = 0;
if (!dev->_is_running) { if (!dev->_is_running) {
...@@ -346,23 +346,23 @@ int cx25821_get_frame(struct cx25821_dev *dev, struct sram_channel *sram_ch) ...@@ -346,23 +346,23 @@ int cx25821_get_frame(struct cx25821_dev *dev, struct sram_channel *sram_ch)
if (IS_ERR(myfile)) { if (IS_ERR(myfile)) {
const int open_errno = -PTR_ERR(myfile); const int open_errno = -PTR_ERR(myfile);
printk(KERN_ERR printk(KERN_ERR
"%s(): ERROR opening file(%s) with errno = %d!\n", "%s(): ERROR opening file(%s) with errno = %d!\n",
__func__, dev->_filename, open_errno); __func__, dev->_filename, open_errno);
return PTR_ERR(myfile); return PTR_ERR(myfile);
} else { } else {
if (!(myfile->f_op)) { if (!(myfile->f_op)) {
printk(KERN_ERR printk(KERN_ERR
"%s: File has no file operations registered!", "%s: File has no file operations registered!",
__func__); __func__);
filp_close(myfile, NULL); filp_close(myfile, NULL);
return -EIO; return -EIO;
} }
if (!myfile->f_op->read) { if (!myfile->f_op->read) {
printk(KERN_ERR printk(KERN_ERR
"%s: File has no READ operations registered!", "%s: File has no READ operations registered!",
__func__); __func__);
filp_close(myfile, NULL); filp_close(myfile, NULL);
return -EIO; return -EIO;
} }
...@@ -389,8 +389,8 @@ int cx25821_get_frame(struct cx25821_dev *dev, struct sram_channel *sram_ch) ...@@ -389,8 +389,8 @@ int cx25821_get_frame(struct cx25821_dev *dev, struct sram_channel *sram_ch)
if (vfs_read_retval < line_size) { if (vfs_read_retval < line_size) {
printk(KERN_INFO printk(KERN_INFO
"Done: exit %s() since no more bytes to \ "Done: exit %s() since no more bytes to \
read from Video file.\n", read from Video file.\n",
__func__); __func__);
break; break;
} }
...@@ -415,15 +415,15 @@ static void cx25821_vidups_handler(struct work_struct *work) ...@@ -415,15 +415,15 @@ static void cx25821_vidups_handler(struct work_struct *work)
container_of(work, struct cx25821_dev, _irq_work_entry); container_of(work, struct cx25821_dev, _irq_work_entry);
if (!dev) { if (!dev) {
printk(KERN_ERR printk(KERN_ERR
"ERROR %s(): since container_of(work_struct) FAILED!\n", "ERROR %s(): since container_of(work_struct) FAILED!\n",
__func__); __func__);
return; return;
} }
cx25821_get_frame(dev, cx25821_get_frame(dev,
dev->channels[dev->_channel_upstream_select]. dev->channels[dev->_channel_upstream_select].
sram_channels); sram_channels);
} }
int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch) int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch)
...@@ -443,22 +443,22 @@ int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch) ...@@ -443,22 +443,22 @@ int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch)
if (IS_ERR(myfile)) { if (IS_ERR(myfile)) {
const int open_errno = -PTR_ERR(myfile); const int open_errno = -PTR_ERR(myfile);
printk(KERN_ERR "%s(): ERROR opening file(%s) with errno = %d!\n", printk(KERN_ERR "%s(): ERROR opening file(%s) with errno = %d!\n",
__func__, dev->_filename, open_errno); __func__, dev->_filename, open_errno);
return PTR_ERR(myfile); return PTR_ERR(myfile);
} else { } else {
if (!(myfile->f_op)) { if (!(myfile->f_op)) {
printk(KERN_ERR printk(KERN_ERR
"%s: File has no file operations registered!", "%s: File has no file operations registered!",
__func__); __func__);
filp_close(myfile, NULL); filp_close(myfile, NULL);
return -EIO; return -EIO;
} }
if (!myfile->f_op->read) { if (!myfile->f_op->read) {
printk(KERN_ERR printk(KERN_ERR
"%s: File has no READ operations registered! \ "%s: File has no READ operations registered! \
Returning.", Returning.",
__func__); __func__);
filp_close(myfile, NULL); filp_close(myfile, NULL);
return -EIO; return -EIO;
...@@ -488,8 +488,8 @@ int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch) ...@@ -488,8 +488,8 @@ int cx25821_openfile(struct cx25821_dev *dev, struct sram_channel *sram_ch)
if (vfs_read_retval < line_size) { if (vfs_read_retval < line_size) {
printk(KERN_INFO printk(KERN_INFO
"Done: exit %s() since no more \ "Done: exit %s() since no more \
bytes to read from Video file.\n", bytes to read from Video file.\n",
__func__); __func__);
break; break;
} }
...@@ -535,8 +535,8 @@ int cx25821_upstream_buffer_prepare(struct cx25821_dev *dev, ...@@ -535,8 +535,8 @@ int cx25821_upstream_buffer_prepare(struct cx25821_dev *dev,
if (!dev->_dma_virt_addr) { if (!dev->_dma_virt_addr) {
printk printk
(KERN_ERR "cx25821: FAILED to allocate memory for Risc \ (KERN_ERR "cx25821: FAILED to allocate memory for Risc \
buffer! Returning.\n"); buffer! Returning.\n");
return -ENOMEM; return -ENOMEM;
} }
...@@ -557,8 +557,8 @@ int cx25821_upstream_buffer_prepare(struct cx25821_dev *dev, ...@@ -557,8 +557,8 @@ int cx25821_upstream_buffer_prepare(struct cx25821_dev *dev,
if (!dev->_data_buf_virt_addr) { if (!dev->_data_buf_virt_addr) {
printk printk
(KERN_ERR "cx25821: FAILED to allocate memory for data \ (KERN_ERR "cx25821: FAILED to allocate memory for data \
buffer! Returning.\n"); buffer! Returning.\n");
return -ENOMEM; return -ENOMEM;
} }
...@@ -653,16 +653,16 @@ int cx25821_video_upstream_irq(struct cx25821_dev *dev, int chan_num, ...@@ -653,16 +653,16 @@ int cx25821_video_upstream_irq(struct cx25821_dev *dev, int chan_num,
} else { } else {
if (status & FLD_VID_SRC_UF) if (status & FLD_VID_SRC_UF)
printk printk
(KERN_ERR "%s: Video Received Underflow Error \ (KERN_ERR "%s: Video Received Underflow Error \
Interrupt!\n", __func__); Interrupt!\n", __func__);
if (status & FLD_VID_SRC_SYNC) if (status & FLD_VID_SRC_SYNC)
printk(KERN_ERR "%s: Video Received Sync Error \ printk(KERN_ERR "%s: Video Received Sync Error \
Interrupt!\n", __func__); Interrupt!\n", __func__);
if (status & FLD_VID_SRC_OPC_ERR) if (status & FLD_VID_SRC_OPC_ERR)
printk(KERN_ERR "%s: Video Received OpCode Error \ printk(KERN_ERR "%s: Video Received OpCode Error \
Interrupt!\n", __func__); Interrupt!\n", __func__);
} }
if (dev->_file_status == END_OF_FILE) { if (dev->_file_status == END_OF_FILE) {
...@@ -818,8 +818,8 @@ int cx25821_vidupstream_init_ch1(struct cx25821_dev *dev, int channel_select, ...@@ -818,8 +818,8 @@ int cx25821_vidupstream_init_ch1(struct cx25821_dev *dev, int channel_select,
if (!dev->_irq_queues) { if (!dev->_irq_queues) {
printk printk
(KERN_ERR "cx25821: create_singlethread_workqueue() for \ (KERN_ERR "cx25821: create_singlethread_workqueue() for \
Video FAILED!\n"); Video FAILED!\n");
return -ENOMEM; return -ENOMEM;
} }
/* 656/VIP SRC Upstream Channel I & J and 7 - Host Bus Interface for /* 656/VIP SRC Upstream Channel I & J and 7 - Host Bus Interface for
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment