drivers/staging/media/atomisp/pci/sh_css_hrt.c

Source file repositories/reference/linux-study-clean/drivers/staging/media/atomisp/pci/sh_css_hrt.c

File Facts

System
Linux kernel
Corpus path
drivers/staging/media/atomisp/pci/sh_css_hrt.c
Extension
.c
Size
1638 bytes
Lines
74
Domain
Driver Families
Bucket
drivers/staging
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

if (state.fifo_valid) {
			IA_CSS_WARNING("FIFO channel %d is not empty", ch);
			not_idle = true;
		}
	}

	return !not_idle;
}

int sh_css_hrt_sp_wait(void)
{
	irq_sw_channel_id_t	irq_id = IRQ_SW_CHANNEL0_ID;
	/*
	 * Wait till SP is idle or till there is a SW2 interrupt
	 * The SW2 interrupt will be used when frameloop runs on SP
	 * and signals an event with similar meaning as SP idle
	 * (e.g. frame_done)
	 */
	while (!sp_ctrl_getbit(SP0_ID, SP_SC_REG, SP_IDLE_BIT) &&
	       ((irq_reg_load(IRQ0_ID,
			      _HRT_IRQ_CONTROLLER_STATUS_REG_IDX) &
		 (1U << (irq_id + IRQ_SW_CHANNEL_OFFSET))) == 0)) {
		udelay(1);
	}

	return 0;
}

Annotation

Implementation Notes