From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752333AbbETHc6 (ORCPT ); Wed, 20 May 2015 03:32:58 -0400 Received: from mail-oi0-f42.google.com ([209.85.218.42]:32855 "EHLO mail-oi0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751276AbbETHc5 (ORCPT ); Wed, 20 May 2015 03:32:57 -0400 MIME-Version: 1.0 In-Reply-To: <53663c3179d0bca26b604f7d175704d1bf26aab4.1432085659.git.joe@perches.com> References: <53663c3179d0bca26b604f7d175704d1bf26aab4.1432085659.git.joe@perches.com> From: Oded Gabbay Date: Wed, 20 May 2015 10:32:26 +0300 Message-ID: Subject: Re: [PATCH 03/12] drm/amdkfd: Use DECLARE_BITMAP To: Joe Perches Cc: "Linux-Kernel@Vger. Kernel. Org" , Oded Gabbay , David Airlie , Maling list - DRI developers Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 20, 2015 at 4:37 AM, Joe Perches wrote: > Use the generic mechanism to declare a bitmap instead of unsigned long. > > It seems that "struct kfd_process.allocated_queue_bitmap" is unused. > Maybe it could be deleted instead. > > Signed-off-by: Joe Perches > --- > drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_priv.h b/drivers/gpu/drm/amd/amdkfd/kfd_priv.h > index f21fcce..aba3e5d 100644 > --- a/drivers/gpu/drm/amd/amdkfd/kfd_priv.h > +++ b/drivers/gpu/drm/amd/amdkfd/kfd_priv.h > @@ -150,8 +150,7 @@ struct kfd_dev { > > const struct kfd2kgd_calls *kfd2kgd; > struct mutex doorbell_mutex; > - unsigned long doorbell_available_index[DIV_ROUND_UP( > - KFD_MAX_NUM_OF_QUEUES_PER_PROCESS, BITS_PER_LONG)]; > + DECLARE_BITMAP(doorbell_available_index, KFD_MAX_NUM_OF_QUEUES_PER_PROCESS); > > void *gtt_mem; > uint64_t gtt_start_gpu_addr; > @@ -473,7 +472,7 @@ struct kfd_process { > /* Size is queue_array_size, up to MAX_PROCESS_QUEUES. */ > struct kfd_queue **queues; > > - unsigned long allocated_queue_bitmap[DIV_ROUND_UP(KFD_MAX_NUM_OF_QUEUES_PER_PROCESS, BITS_PER_LONG)]; > + DECLARE_BITMAP(allocated_queue_bitmap, KFD_MAX_NUM_OF_QUEUES_PER_PROCESS); > > /*Is the user space process 32 bit?*/ > bool is_32bit_user_mode; > -- > 2.1.2 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ Thanks! I indeed deleted the allocated_queue_bitmap and squashed it into your patch. It was a residue from a very early version. Applied to my -next branch. Oded