Re: [PATCH 2/2] staging: media: atomisp2: Replace kfree()/vfree() with kvfree()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Jul 8, 2017 at 4:58 AM, Bernd Petrovitsch
<bernd@xxxxxxxxxxxxxxxxxxx> wrote:
> On Fri, 2017-07-07 at 20:41 -0400, Amitoj Kaur Chawla wrote:
> [...]
>> --- a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c
>> +++ b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c
>> @@ -117,11 +117,7 @@ void *atomisp_kernel_zalloc(size_t bytes, bool
>> zero_mem)
>>   */
>>  void atomisp_kernel_free(void *ptr)
>>  {
>> -     /* Verify if buffer was allocated by vmalloc() or kmalloc()
>> */
>> -     if (is_vmalloc_addr(ptr))
>> -             vfree(ptr);
>> -     else
>> -             kfree(ptr);
>> +     kvfree(ptr);
>>  }
>>
>>  /*
>
> Why not get rid of the trivial wrapper function completely?
>

Oh yes, i'll send a v2.

Amitoj
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux