xref: /linux/drivers/staging/media/atomisp/notes.txt (revision c6fbb759)
1Some notes about the working of the atomisp drivers (learned while working
2on cleaning it up).
3
4The atomisp seems to be a generic DSP(ISP) like processor without a fixed
5pipeline. It does not have its own memory, but instead uses main memory.
6The ISP has its own address-space and main memory needs to be mapped into
7its address space through the ISP's MMU.
8
9Memory is allocated by the hmm code. hmm_alloc() returns an ISP virtual
10address. The hmm code keeps a list of all allocations and when necessary
11the hmm code finds the backing hmm-buffer-object (hmm_bo) by looking
12up the hmm_bo based on the ISP virtual address.
13
14The actual processing pipeline is made by loading one or more programs,
15called binaries. The shisp_240??0_v21.bin firmware file contains many
16different binaries. Binaries are picked by filling a ia_css_binary_descr
17struct with various input and output parameters and then calling
18ia_css_binary_find(). Some binaries support creating multiple outputs
19(preview + video frame?) at the same time.
20
21For example for the /dev/video0 preview node load_preview_binaries()
22from atomisp/pci/sh_css.c is called and then loads a preview and
23optionally a scalar binary. Note when digital zoom is disabled
24(it is enabled by default) only the preview binary is loaded.
25So in this case a single binary handles the entire pipeline.
26
27Since getting a picture requires multiple processing steps,
28this means that unlike in fixed pipelines the soft pipelines
29on the ISP can do multiple processing steps in a single pipeline
30element (in a single binary).
31