Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c1183315 authored by Surya Prakash Sivaraj's avatar Surya Prakash Sivaraj Committed by Madan Koyyalamudi
Browse files

qcacld-3.0: Handle reset case for P2P_SET_NOA

For resetting NOA, "P2P_SET_NOA 0 0 0" command will be
used. Since duration and interval are same, currently the
set will be rejected.

Handle the count 0 case and bypass the existing validation
for periodic NOA.

Change-Id: I5294d7bcdd70d9280e50167c961d2e9c525fca4c
CRs-Fixed: 3054252
parent c9109277
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
/*
 * Copyright (c) 2012-2021 The Linux Foundation. All rights reserved.
 * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
 *
 * Permission to use, copy, modify, and/or distribute this software for
 * any purpose with or without fee is hereby granted, provided that the
@@ -527,7 +528,7 @@ int hdd_set_p2p_noa(struct net_device *dev, uint8_t *command)
		noa.single_noa_duration = duration;
		noa.ps_selection = P2P_POWER_SAVE_TYPE_SINGLE_NOA;
	} else {
		if (duration >= interval) {
		if (count && (duration >= interval)) {
			hdd_err("Duration should be less than interval");
			return -EINVAL;
		}