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

Commit aeef010a authored by Mike Marciniszyn's avatar Mike Marciniszyn Committed by Doug Ledford
Browse files

IB/hfi1: fix sdma_descq_cnt parameter parsing



The boolean tests should have been or-ed.

Reported-by: default avatarDavid Binderman <dcb314@hotmail.com>
Reviewed-by: default avatarJubin John <jubin.john@intel.com>
Signed-off-by: default avatarMike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
parent e1df0068
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -737,7 +737,7 @@ u16 sdma_get_descq_cnt(void)
	 */
	if (!is_power_of_2(count))
		return SDMA_DESCQ_CNT;
	if (count < 64 && count > 32768)
	if (count < 64 || count > 32768)
		return SDMA_DESCQ_CNT;
	return count;
}