> -----Original Message----- > From: amd-gfx [mailto:amd-gfx-bounces at lists.freedesktop.org] On Behalf > Of zhoucm1 > Sent: Thursday, December 22, 2016 5:01 PM > To: Yu, Xiangliang <Xiangliang.Yu at amd.com>; amd- > gfx at lists.freedesktop.org > Cc: Liu, Monk <Monk.Liu at amd.com> > Subject: Re: [PATCH 1/1] drm/amdgpu/gfx8: add support kernel interface > queue(KIQ) > > > > On 2016å¹´12æ??22æ?¥ 16:58, Yu, Xiangliang wrote: > >> -----Original Message----- > >> From: Zhou, David(ChunMing) > >> Sent: Tuesday, December 20, 2016 5:49 PM > >> To: Yu, Xiangliang <Xiangliang.Yu at amd.com>; amd- > >> gfx at lists.freedesktop.org > >> Cc: Liu, Monk <Monk.Liu at amd.com> > >> Subject: Re: [PATCH 1/1] drm/amdgpu/gfx8: add support kernel > >> interface > >> queue(KIQ) > >> > >> > >> > >> On 2016å¹´12æ??20æ?¥ 17:48, Xiangliang Yu wrote: > >>> + if (kiq->eop_obj == NULL) { > >>> + r = amdgpu_bo_create(adev, > >>> + MEC_HPD_SIZE, > >>> + PAGE_SIZE, true, > >>> + AMDGPU_GEM_DOMAIN_GTT, 0, NULL, > >> NULL, > >>> + &kiq->eop_obj); > >>> + if (r) { > >>> + dev_warn(adev->dev, "(%d) create HDP EOP bo > >> failed\n", r); > >>> + return r; > >>> + } > >>> + } > >>> + > >>> + r = amdgpu_bo_reserve(kiq->eop_obj, false); > >>> + if (unlikely(r != 0)) { > >>> + gfx_v8_0_kiq_fini(adev); > >>> + return r; > >>> + } > >>> + > >>> + r = amdgpu_bo_pin(kiq->eop_obj, AMDGPU_GEM_DOMAIN_GTT, > >>> + &kiq->eop_gpu_addr); > >>> + if (r) { > >>> + dev_warn(adev->dev, "(%d) pin HDP EOP bo failed\n", r); > >>> + gfx_v8_0_kiq_fini(adev); > >>> + return r; > >>> + } > >>> + > >>> + r = amdgpu_bo_kmap(kiq->eop_obj, (void **)&hpd); > >> you can use amdgpu_bo_create/free_kernel helper to do these. > > First I have same idea, but I find rlc_init & mec_init hasn't use this helper, I > donâ??t know why. So just following rlc_init& mec_init behavior. > > > > Could you tell me why not use donâ??t use amdpgu_bo_create/free_kerenl > helper in rlc_init & mec_init? > Yeah, I realized them as well, they certainly need to use helper, which could > be forgot by code creator. You can do that with a separate patch for it, that > would be fine. Ok, thanks! > > _______________________________________________ > amd-gfx mailing list > amd-gfx at lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx