Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-03 Thread Harshit Mogalapalli
Hi Boris, On 03/04/24 12:47, Boris Brezillon wrote: On Tue, 2 Apr 2024 07:14:11 -0700 Harshit Mogalapalli wrote: Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and NULL(when create is false and if there is no poool attached to the VM) - Change the function to return

Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-03 Thread Boris Brezillon
On Tue, 2 Apr 2024 07:14:11 -0700 Harshit Mogalapalli wrote: > Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and > NULL(when create is false and if there is no poool attached to the > VM) > - Change the function to return error pointers, when pool is > NULL return

Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-02 Thread Dan Carpenter
On Tue, Apr 02, 2024 at 05:19:25PM +0200, Boris Brezillon wrote: > On Tue, 2 Apr 2024 17:44:18 +0300 > Dan Carpenter wrote: > > > On Tue, Apr 02, 2024 at 04:38:38PM +0200, Boris Brezillon wrote: > > > On Tue, 2 Apr 2024 07:14:11 -0700 > > > Harshit Mogalapalli wrote: > > > > > > > Currently

Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-02 Thread Boris Brezillon
On Tue, 2 Apr 2024 17:44:18 +0300 Dan Carpenter wrote: > On Tue, Apr 02, 2024 at 04:38:38PM +0200, Boris Brezillon wrote: > > On Tue, 2 Apr 2024 07:14:11 -0700 > > Harshit Mogalapalli wrote: > > > > > Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and > > > NULL(when create is

Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-02 Thread Dan Carpenter
On Tue, Apr 02, 2024 at 04:38:38PM +0200, Boris Brezillon wrote: > On Tue, 2 Apr 2024 07:14:11 -0700 > Harshit Mogalapalli wrote: > > > Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and > > NULL(when create is false and if there is no poool attached to the > >

Re: [PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-02 Thread Boris Brezillon
On Tue, 2 Apr 2024 07:14:11 -0700 Harshit Mogalapalli wrote: > Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and > NULL(when create is false and if there is no poool attached to the ^ pool > VM) > - Change the function to

[PATCH v3] drm/panthor: Fix couple of NULL vs IS_ERR() bugs

2024-04-02 Thread Harshit Mogalapalli
Currently panthor_vm_get_heap_pool() returns both ERR_PTR() and NULL(when create is false and if there is no poool attached to the VM) - Change the function to return error pointers, when pool is NULL return -ENOENT - Also handle the callers to check for IS_ERR() on