Re: [PATCH v2 2/3] platform/x86: asus_wmi: Support fan boost mode on FX505DY/FX705DY

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Leonid,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on linus/master]
[also build test ERROR on v5.4-rc6 next-20191031]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Leonid-Maksymchuk/asus_wmi-Support-of-ASUS-TUF-laptops-on-Ryzen-CPUs/20191105-054154
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git a99d8080aaf358d5d23581244e5da23b35e340b9
config: x86_64-rhel (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

   drivers/platform/x86/asus-wmi.c: In function 'asus_wmi_handle_event_code':
>> drivers/platform/x86/asus-wmi.c:2017:57: error: expected ')' before '{' token
       (code == NOTIFY_KBD_FBM || code == NOTIFY_KBD_FBM_2) {
                                                            ^
>> drivers/platform/x86/asus-wmi.c:2028:1: error: expected expression before '}' token
    }
    ^
   At top level:
   drivers/platform/x86/asus-wmi.c:1909:12: warning: 'is_display_toggle' defined but not used [-Wunused-function]
    static int is_display_toggle(int code)
               ^~~~~~~~~~~~~~~~~
   drivers/platform/x86/asus-wmi.c:1677:12: warning: 'fan_boost_mode_switch_next' defined but not used [-Wunused-function]
    static int fan_boost_mode_switch_next(struct asus_wmi *asus)
               ^~~~~~~~~~~~~~~~~~~~~~~~~~

vim +2017 drivers/platform/x86/asus-wmi.c

  1966	
  1967	static void asus_wmi_handle_event_code(int code, struct asus_wmi *asus)
  1968	{
  1969		int orig_code;
  1970		unsigned int key_value = 1;
  1971		bool autorelease = 1;
  1972	
  1973		orig_code = code;
  1974	
  1975		if (asus->driver->key_filter) {
  1976			asus->driver->key_filter(asus->driver, &code, &key_value,
  1977						 &autorelease);
  1978			if (code == ASUS_WMI_KEY_IGNORE)
  1979				return;
  1980		}
  1981	
  1982		if (code >= NOTIFY_BRNUP_MIN && code <= NOTIFY_BRNUP_MAX)
  1983			code = ASUS_WMI_BRN_UP;
  1984		else if (code >= NOTIFY_BRNDOWN_MIN && code <= NOTIFY_BRNDOWN_MAX)
  1985			code = ASUS_WMI_BRN_DOWN;
  1986	
  1987		if (code == ASUS_WMI_BRN_DOWN || code == ASUS_WMI_BRN_UP) {
  1988			if (acpi_video_get_backlight_type() == acpi_backlight_vendor) {
  1989				asus_wmi_backlight_notify(asus, orig_code);
  1990				return;
  1991			}
  1992		}
  1993	
  1994		if (code == NOTIFY_KBD_BRTUP) {
  1995			kbd_led_set_by_kbd(asus, asus->kbd_led_wk + 1);
  1996			return;
  1997		}
  1998		if (code == NOTIFY_KBD_BRTDWN) {
  1999			kbd_led_set_by_kbd(asus, asus->kbd_led_wk - 1);
  2000			return;
  2001		}
  2002		if (code == NOTIFY_KBD_BRTTOGGLE) {
  2003			if (asus->kbd_led_wk == asus->kbd_led.max_brightness)
  2004				kbd_led_set_by_kbd(asus, 0);
  2005			else
  2006				kbd_led_set_by_kbd(asus, asus->kbd_led_wk + 1);
  2007			return;
  2008		}
  2009	
  2010		if (code == NOTIFY_FNLOCK_TOGGLE) {
  2011			asus->fnlock_locked = !asus->fnlock_locked;
  2012			asus_wmi_fnlock_update(asus);
  2013			return;
  2014		}
  2015	
  2016		if (asus->fan_boost_mode_available &&
> 2017				(code == NOTIFY_KBD_FBM || code == NOTIFY_KBD_FBM_2) {
  2018			fan_boost_mode_switch_next(asus);
  2019			return;
  2020		}
  2021	
  2022		if (is_display_toggle(code) && asus->driver->quirks->no_display_toggle)
  2023			return;
  2024	
  2025		if (!sparse_keymap_report_event(asus->inputdev, code,
  2026						key_value, autorelease))
  2027			pr_info("Unknown key %x pressed\n", code);
> 2028	}
  2029	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux