Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-08 Thread Zack Rusin
> On Feb 8, 2021, at 15:23, Christian König wrote: > > Am 08.02.21 um 21:21 schrieb Zack Rusin: >>> On Feb 8, 2021, at 08:35, Christian König wrote: >>> >>> Hi Zack, >>> >>> ok we figured out how to do this correctly. >>> >>> Basically using the pdev->kobj instead of the

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-08 Thread Christian König
Am 08.02.21 um 21:21 schrieb Zack Rusin: On Feb 8, 2021, at 08:35, Christian König wrote: Hi Zack, ok we figured out how to do this correctly. Basically using the pdev->kobj instead of the drm->primary->kdev->kobj pointer worked quite well. I've just send the latest patches to the mailing

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-08 Thread Zack Rusin
> On Feb 8, 2021, at 08:35, Christian König wrote: > > Hi Zack, > > ok we figured out how to do this correctly. > > Basically using the pdev->kobj instead of the drm->primary->kdev->kobj > pointer worked quite well. > > I've just send the latest patches to the mailing list. If you don't

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v4

2021-02-08 Thread Nirmoy
Hi Christian, On 2/8/21 2:32 PM, Christian König wrote: This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. v2: fix typo in

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-08 Thread Daniel Vetter
On Mon, Feb 8, 2021 at 2:35 PM Christian König wrote: > > Hi Zack, > > ok we figured out how to do this correctly. > > Basically using the pdev->kobj instead of the drm->primary->kdev->kobj > pointer worked quite well. Note drm_device->pdev is gone, so make sure everything still compiles. You

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-08 Thread Christian König
Hi Zack, ok we figured out how to do this correctly. Basically using the pdev->kobj instead of the drm->primary->kdev->kobj pointer worked quite well. I've just send the latest patches to the mailing list. If you don't have any objections I will commit that tomorrow with your and Daniels

[PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v4

2021-02-08 Thread Christian König
This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. v2: fix typo in KFD and avoid 64bit divide v3: fix init order in VMWGFX v4:

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-03 Thread Christian König
Hi Zack, thanks I can take over again from here on. Quite busy today, but I think I can go over the code once more tomorrow. Thanks for the help, Christian. Am 03.02.21 um 03:45 schrieb Zack Rusin: Just had a quick peek. The issue is that you can’t attach to the drm device (card0) because

Re: [Linux-graphics-maintainer] [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-02 Thread Zack Rusin
Just had a quick peek. The issue is that you can’t attach to the drm device (card0) because it hasn’t been registered yet (drm device registration is last in the vmw_probe in vmwgfx_drv.c via the drm_dev_register). So dev->primary->kdev->kobj that you’re using as argument to

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-02 Thread Zack Rusin
Ah, yes, sorry, I missed that. I just double checked and it fails with: kobject_add_internal failed for memory_accounting (error: -2 parent: card0) which breaks the probe and the driver won’t load. I won’t have time to look into it until tomorrow though. z > On Feb 2, 2021, at 10:16,

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-02 Thread Christian König
Hi Zack, can you also give it a quick smoke test? I'm not sure if I wired up all the sysfs magic correctly inside vmwgfx, but I currently don't have a setup where I can test this. Thanks, Christian. Am 02.02.21 um 16:14 schrieb Zack Rusin: Looks good. There’s probably not much reason to

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-02 Thread Zack Rusin
Looks good. There’s probably not much reason to call it ttm_memory anymore as it only deals with ttm_mem_glob, we’ll likely fold it in after you submit. Thanks. Reviewed-by: Zack Rusin z > On Feb 2, 2021, at 08:04, Christian König wrote: > > Ping? > > Especially Roland and Zack do you

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-02-02 Thread Christian König
Ping? Especially Roland and Zack do you have any objections to this? Regards, Christian. Am 28.01.21 um 14:16 schrieb Christian König: This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of

[PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v3

2021-01-28 Thread Christian König
This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. v2: fix typo in KFD and avoid 64bit divide v3: fix init order in VMWGFX

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2021-01-26 Thread kernel test robot
Hi "Christian, I love your patch! Yet something to improve: [auto build test ERROR on drm-tip/drm-tip] [also build test ERROR on next-20210125] [cannot apply to drm-intel/for-linux-next drm-exynos/exynos-drm-next tegra-drm/drm/tegra/for-next linus/master drm/drm-next v5.11-rc5] [If your patch

[PATCH 2/3] drm/ttm: move memory accounting into vmwgfx v2

2021-01-26 Thread Christian König
This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. v2: fix typo in KFD and avoid 64bit divide Signed-off-by: Christian König

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2021-01-26 Thread kernel test robot
Hi "Christian, I love your patch! Perhaps something to improve: [auto build test WARNING on drm-tip/drm-tip] [also build test WARNING on next-20210125] [cannot apply to drm-intel/for-linux-next drm-exynos/exynos-drm-next tegra-drm/drm/tegra/for-next linus/master drm/drm-next v5.11-rc5] [If your

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2021-01-26 Thread kernel test robot
Hi "Christian, I love your patch! Yet something to improve: [auto build test ERROR on drm-tip/drm-tip] [also build test ERROR on next-20210125] [cannot apply to drm-intel/for-linux-next drm-exynos/exynos-drm-next tegra-drm/drm/tegra/for-next linus/master drm/drm-next v5.11-rc5] [If your patch

[PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2021-01-25 Thread Christian König
This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. Signed-off-by: Christian König ---

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2020-11-18 Thread kernel test robot
Hi "Christian, I love your patch! Yet something to improve: [auto build test ERROR on next-20201117] [cannot apply to linus/master v5.10-rc4 v5.10-rc3 v5.10-rc2 v5.10-rc4] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use

Re: [PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2020-11-18 Thread kernel test robot
Hi "Christian, I love your patch! Yet something to improve: [auto build test ERROR on next-20201117] [cannot apply to linus/master v5.10-rc4 v5.10-rc3 v5.10-rc2 v5.10-rc4] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use

[PATCH 2/3] drm/ttm: move memory accounting into vmwgfx

2020-11-17 Thread Christian König
This is just another feature which is only used by VMWGFX, so move it into the driver instead. I've tried to add the accounting sysfs file to the kobject of the drm minor, but I'm not 100% sure if this works as expected. Signed-off-by: Christian König ---