From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751341AbdEBNYJ (ORCPT ); Tue, 2 May 2017 09:24:09 -0400 Received: from mail-wm0-f42.google.com ([74.125.82.42]:38083 "EHLO mail-wm0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750713AbdEBNYG (ORCPT ); Tue, 2 May 2017 09:24:06 -0400 Date: Tue, 2 May 2017 15:24:02 +0200 From: =?utf-8?B?TWljaGHFgiBLxJlwaWXFhA==?= To: Jonathan Woithe Cc: Darren Hart , Andy Shevchenko , platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 01/10] platform/x86: fujitsu-laptop: introduce fext_*() helper functions Message-ID: <20170502132402.GB6808@ozzy.nask.waw.pl> References: <20170424133334.7064-1-kernel@kempniu.pl> <20170424133334.7064-2-kernel@kempniu.pl> <20170501131315.GB25546@marvin.atrad.com.au> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20170501131315.GB25546@marvin.atrad.com.au> User-Agent: Mutt/1.8.2 (2017-04-18) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > > @@ -272,9 +292,9 @@ static int bl_get_brightness(struct backlight_device *b) > > static int bl_update_status(struct backlight_device *b) > > { > > if (b->props.power == FB_BLANK_POWERDOWN) > > - call_fext_func(FUNC_BACKLIGHT, 0x1, 0x4, 0x3); > > + fext_backlight(0x1, 0x4, 0x3); > > else > > - call_fext_func(FUNC_BACKLIGHT, 0x1, 0x4, 0x0); > > + fext_backlight(0x1, 0x4, 0x0); > > > > return set_lcd_level(b->props.brightness); > > } > > @@ -610,22 +630,22 @@ static int logolamp_set(struct led_classdev *cdev, > > if (brightness < LED_FULL) > > always = FUNC_LED_OFF; > > > > - ret = call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_POWERON, poweron); > > + ret = fext_leds(0x1, LOGOLAMP_POWERON, poweron); > > if (ret < 0) > > return ret; > > > > - return call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_ALWAYS, always); > > + return fext_leds(0x1, LOGOLAMP_ALWAYS, always); > > } > > I've only just noticed this. For the led calls we have symbolic identifiers > defined for the "features" parameter, but in the backlight case we are still > using arbitrary numeric constants. Although not necessary for this patch > set, we should consider adding feature identifiers for the other fext_*() calls. > Similarly for the "op" parameter where it makes sense to do so. Good point, I will keep that in mind for the next patch series. -- Best regards, Michał Kępień