mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 17:25:35 +03:00
coe: disable allocation power of 2 check
In fringe unexpected cases, HSB (Holoscan sensor bringe) sends image byte offset larger then allocated image size (e.g. if HSB just sends incorrect packet, or is configured incorrectly for a different image size. or just packet corruption). In such cases, we run into SMMU faults. To mitigate this, a buffer size of two check was introduced so even were this to happen, it would not cause SMMU errors. However, the support for this in UMD is not complete. Therefore, disable this check until UMD is able to comply with this buffer constraint. Jira L4T-7463 Change-Id: I2de31740284627ca117f1fa0a28bde2ef9a82785 Signed-off-by: Rakibul Hassan <rakibulh@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3419644 Reviewed-by: Igor Mitsyanko <imitsyanko@nvidia.com> GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com> Reviewed-by: Narendra Kondapalli <nkondapalli@nvidia.com> Reviewed-by: svcacv <svcacv@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
bbcbfbb49e
commit
66235b7274
@@ -639,7 +639,12 @@ static int coe_ioctl_handle_capture_req(struct coe_channel_state * const ch,
|
||||
* up to the next closest power of two boundary to eliminate a risk of a malformed
|
||||
* incoming network packet triggerring invalid memory access.
|
||||
*/
|
||||
#define L4T7463
|
||||
#ifndef L4T7463
|
||||
alloc_size_min = roundup_pow_of_two(req->buf_size);
|
||||
#else
|
||||
alloc_size_min = req->buf_size;
|
||||
#endif
|
||||
|
||||
if (alloc_size_min > buf_max_size) {
|
||||
dev_err(ch->dev, "CAPTURE_REQ: capture too long %u\n", req->buf_size);
|
||||
|
||||
Reference in New Issue
Block a user