From: Takashi Iwai Subject: Re: [PATCH 1/1] alsa-driver: RHEL 6.1 compilation fix Date: Tue, 08 Nov 2011 17:00:36 +0100 Message-ID: References: <1320767247-20933-1-git-send-email-kozerkov@parallels.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 970E4103903 for ; Tue, 8 Nov 2011 17:00:37 +0100 (CET) In-Reply-To: <1320767247-20933-1-git-send-email-kozerkov@parallels.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Konstantin Ozerkov Cc: "Denis V. Lunev" , alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Tue, 8 Nov 2011 19:47:27 +0400, Konstantin Ozerkov wrote: > > RHEL 6.1 (2.6.32-132.*) kernels already have hex_to_bin() function. > Tune check in the alsa-driver/include/adriver.h > > Tested on Scientific Linux 6.1 (RHEL 6.1 clone), kernels: > 2.6.32-131.0.15.el6.x86_64 (original, from DVD installation) > 2.6.32-131.17.1.el6.x86_64 (last security update) > > Signed-off-by: Konstantin Ozerkov > Signed-off-by: Denis V. Lunev Thanks, applied now. Takashi > diff --git a/include/adriver.h b/include/adriver.h > index d9c7dee..aeb084e 100644 > --- a/include/adriver.h > +++ b/include/adriver.h > @@ -1920,6 +1920,8 @@ blocking_notifier_chain_unregister(struct blocking_notifier_head *nh, > > /* hex_to_bin() */ > #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 35) > +/* RHEL 6.1 kernels has version 2.6.32, but already have hex_to_bin() */ > +#if !defined(RHEL_RELEASE_CODE) || RHEL_RELEASE_CODE < RHEL_RELEASE_VERSION(6,1) > static inline int hex_to_bin(char c) > { > if (c >= '0' && c <= '9') > @@ -1931,6 +1933,7 @@ static inline int hex_to_bin(char c) > return -1; > } > #endif > +#endif > > #ifndef CONFIG_HAVE_VZALLOC > #include > -- > 1.7.1 >