Commit 6e24360
Revert "libcamera: rkisp1: Eliminate hard-coded resizer limits"
This reverts commit e85c7dd.
Linux kernel predating 6.4 (specifically commit 7cfb35d3a800 ("media:
rkisp1: Implement ENUM_FRAMESIZES") do not have the ioctl in rkisp1
driver required to dynamically query the resizer limits.
Because of that, maxResolution and minResolution are both {0, 0}
(default value for Size objects) which means filterSensorResolution()
will create an entry for the sensor in sensorSizesMap_ but because the
sensor resolution cannot fit inside the min and max resolution of the
rkisp1, no size is put into this entry in sensorSizesMap_.
On the next call to filterSensorResolution(),
sensorSizesMap_.find(sensor) will return the entry but when attempting
to call back() on iter->second, it'll trigger an assert because the size
array is empty.
Linux kernel 6.1 is supported until December 2027, so it seems premature
to get rid of those hard-coded resizer limits before this happens.
Let's restore the hard-coded resizer limits as fallbacks, actual limits
are still queried from the driver on recent enough kernels.
Fixes: 7615454 ("pipeline: rkisp1: Filter out sensor sizes not supported by the pipeline")
Signed-off-by: Quentin Schulz <[email protected]>
Reviewed-by: Jacopo Mondi <[email protected]>
Reviewed-by: Laurent Pinchart <[email protected]>
Signed-off-by: Laurent Pinchart <[email protected]>1 parent 5b73d25 commit 6e24360
2 files changed
+17
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
58 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
59 | 62 | | |
60 | 63 | | |
61 | 64 | | |
| |||
517 | 520 | | |
518 | 521 | | |
519 | 522 | | |
520 | | - | |
521 | | - | |
| 523 | + | |
| 524 | + | |
522 | 525 | | |
523 | 526 | | |
| 527 | + | |
| 528 | + | |
524 | 529 | | |
525 | 530 | | |
526 | 531 | | |
| |||
542 | 547 | | |
543 | 548 | | |
544 | 549 | | |
| 550 | + | |
| 551 | + | |
545 | 552 | | |
546 | 553 | | |
547 | 554 | | |
| |||
555 | 562 | | |
556 | 563 | | |
557 | 564 | | |
558 | | - | |
| 565 | + | |
| 566 | + | |
559 | 567 | | |
560 | 568 | | |
561 | 569 | | |
562 | 570 | | |
563 | | - | |
| 571 | + | |
| 572 | + | |
564 | 573 | | |
565 | 574 | | |
566 | 575 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
| 38 | + | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
0 commit comments