Re: [PATCH v2] swiotlb: Make SWIOTLB_NO_FORCE perform no allocation

2021-03-22 Thread Christoph Hellwig
On Sat, Mar 20, 2021 at 08:37:40PM -0700, Florian Fainelli wrote: > - if (!strcmp(str, "force")) { > + if (!strcmp(str, "force")) > swiotlb_force = SWIOTLB_FORCE; > - } else if (!strcmp(str, "noforce")) { > + else if (!strcmp(str, "noforce")) > swiotlb_fo

[PATCH v2] swiotlb: Make SWIOTLB_NO_FORCE perform no allocation

2021-03-20 Thread Florian Fainelli
When SWIOTLB_NO_FORCE is used, there should really be no allocations of default_nslabs to occur since we are not going to use those slabs. If a platform was somehow setting swiotlb_no_force and a later call to swiotlb_init() was to be made we would still be proceeding with allocating the default SW