Received: by 10.192.165.156 with SMTP id m28csp712423imm; Thu, 19 Apr 2018 06:24:38 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+9Lg/f51eCKOIHE2Lbz7of7o/dip8SxdubkIxJBf24PPvwdNHR0YHNs7xMn46VMqZ/6J7w X-Received: by 2002:a17:902:2924:: with SMTP id g33-v6mr3667937plb.26.1524144278637; Thu, 19 Apr 2018 06:24:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524144278; cv=none; d=google.com; s=arc-20160816; b=QCgzhuvyqI45IVbRgVKBZROWvAxtXLGpWsyNAZ11V5Ib4inIAFLppPmTasGpd7sTIr gXWV5XpCN/3jfZGLEZL5r4ID2hWe4k5pQyDJcqW9ndeWmBJ8N8YlpGhKEHlxqqvrrFM4 KAa7FLnN7H00LK7DyoXy6KPje/kSGpeOFbh7shSCtBBRLE5yvTnXprWGwBjdvU/6P0y3 QTekoyL45slI0u1lrTY6yl9tXn49C0YrcJZDHBvVhyYPLPfC/msu2j0vn+C/vCUOqUdV +L0HDaAzS8tL2zjOr8LVUg7E8UmxtZTmIfXzDc2zs4CZv6IOLfL0Uv8atUOzQv6g+ePR yL8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=yVAnN10LSmvQrWyu7rN12OB5ah3efD12aDmgntl7poE=; b=fEu4p2cWUzkNgI+vTRl0tRkKQD/lM0RvJcoMUmUXuCrdzFxo0q9e1thW2Zr7WaeqnV ZaFAteO/Vx+9l2XUH/pgCydS1DqKi9Est+CXNCPZoKSKm84xzgcTI3LX22tVaDIUyf9X mrq4WyFmKDpuQi6UqnC5+Sjh32GsoF6KNcIR32ArjTn1s+sYV0nKrdV05u5ggxuao72P ycZGWO0v17VVYWdf/kOiQt/PrmgGJXsCyRWP1Q/O6uUYlHOqH8QXq82/1974G3XQXALH t3RVP+hOF8M5OrcRcCf5PB4nl5j21hCSox7ibUb2a3kbvbVzemFgKr27pSUw2ZtQWJag eRuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GHXIa3Re; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q13si3001001pgp.533.2018.04.19.06.24.24; Thu, 19 Apr 2018 06:24:38 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GHXIa3Re; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753099AbeDSNW7 (ORCPT + 99 others); Thu, 19 Apr 2018 09:22:59 -0400 Received: from mail-lf0-f66.google.com ([209.85.215.66]:34319 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752703AbeDSNW5 (ORCPT ); Thu, 19 Apr 2018 09:22:57 -0400 Received: by mail-lf0-f66.google.com with SMTP id r7-v6so156993lfr.1; Thu, 19 Apr 2018 06:22:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=yVAnN10LSmvQrWyu7rN12OB5ah3efD12aDmgntl7poE=; b=GHXIa3Re5YVBWIkr38P/0RniF5MzXKLs7QvvRUhWO3I4JtdO1Vg27ti5OCEc4y5PCt 7lshztUlaDqQP7DreKiBmVMXafGkm6ILHxDRKLwzG3mww3YGplntfVzGNdW59LSQgZs6 4DxF2sp1JpkN09rHDRlKVxQbpHPGuqnS+4eaAChmj7jCkaNQy0YohIrmv09zKvLXvv3C 5cTzT4sHwRzjGM1cfX3Qf/M+nucXB+jBMMrYm/59nNj7C12H6bldcrtrUONoiBN6a07N jRt4mFlB+yBLQBjvhebRcQC6eATNHUMX+BaXI6RwDMfftVQgqPdlR69BF5rN+l1ltMT6 W+4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=yVAnN10LSmvQrWyu7rN12OB5ah3efD12aDmgntl7poE=; b=gV3Wo++eSy2YSyUu31CXbc8iU8k4AvK1KUjhZmsvqHxMEiYyYYfnC+WPUTwR9xYQxj En0Rsq2uPcFBCCaL9GyTXxFjzypP/GsaLv0U+sa7jtclXvAcdthpf4+yR628o7Ymqh7b Ih1+ta86UAjcPqv89PQYSaUMcFbsuYkjebEEiLw9fhlt4GvrYsXuEeQ/XBXTtalBTEEX gKNl3A6r+2RhmIuAhD2UvKAY1owqb/HonSz29Ku80N8whkI+JkawgH1zVtnMGfQWErGR jmttYarc1eOXXWrS+2lUNEJOU8Va3B8GJ/QSuTkBPjxtVUf6HUsRxUANarHUAQihJq7P 6cnw== X-Gm-Message-State: ALQs6tBsQJqgXz3qiqTa19e4v3h7iVcUskU/5XyONJKq4QfeGdyKuH5S OVx3HkNA+GgjFSL1fPlxSpI6F9X/zaw= X-Received: by 10.46.47.7 with SMTP id v7mr4261551ljv.56.1524144175474; Thu, 19 Apr 2018 06:22:55 -0700 (PDT) Received: from [10.17.182.9] (ll-74.141.223.85.sovam.net.ua. [85.223.141.74]) by smtp.gmail.com with ESMTPSA id a124-v6sm749114lfe.18.2018.04.19.06.22.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Apr 2018 06:22:54 -0700 (PDT) Subject: Re: [Xen-devel] [PATCH] Input: xen-kbdfront - allow better run-time configuration To: Juergen Gross , Jason Andryuk Cc: xen-devel@lists.xenproject.org, linux-input@vger.kernel.org, open list , dmitry.torokhov@gmail.com, lyan@suse.com, Boris Ostrovsky , andrii_chepurnyi@epam.com, Oleksandr Andrushchenko References: <20180418150445.9805-1-andr2000@gmail.com> <2bff035e-303e-d644-5f51-5e64150c097c@gmail.com> <5ed20b99-263d-d906-9349-d064eead36ad@gmail.com> From: Oleksandr Andrushchenko Message-ID: <1d737998-6b90-ba33-bafa-8a8d4dc568d8@gmail.com> Date: Thu, 19 Apr 2018 16:22:53 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/19/2018 04:19 PM, Juergen Gross wrote: > On 19/04/18 15:12, Oleksandr Andrushchenko wrote: >> On 04/19/2018 04:10 PM, Jason Andryuk wrote: >>> On Thu, Apr 19, 2018 at 9:01 AM, Oleksandr Andrushchenko >>> wrote: >>>> Ok, so I'll send v2 with the following changes: >>>> >>>> diff --git a/drivers/input/misc/xen-kbdfront.c >>>> b/drivers/input/misc/xen-kbdfront.c >>>> index a3306aad40b0..d8cca212f737 100644 >>>> --- a/drivers/input/misc/xen-kbdfront.c >>>> +++ b/drivers/input/misc/xen-kbdfront.c >>>> @@ -51,13 +51,13 @@ module_param_array(ptr_size, int, NULL, 0444); >>>>   MODULE_PARM_DESC(ptr_size, >>>>          "Pointing device width, height in pixels (default 800,600)"); >>>> >>>> -static unsigned int no_ptr_dev; >>>> -module_param(no_ptr_dev, uint, 0); >>>> +static bool no_ptr_dev; >>>> +module_param(no_ptr_dev, bool, 0); >>>>   MODULE_PARM_DESC(no_ptr_dev, >>>>          "If set then no virtual pointing device exposed to the guest"); >>>> >>>> -static unsigned int no_kbd_dev; >>>> -module_param(no_kbd_dev, uint, 0); >>>> +static bool no_kbd_dev; >>>> +module_param(no_kbd_dev, bool, 0); >>>>   MODULE_PARM_DESC(no_kbd_dev, >>>>          "If set then no virtual keyboard device exposed to the guest"); >>> I prefer direct logic over inverse logic.  Maybe just use kbd_dev, >>> default to true, but allow it to be set off? >>> >>> static bool kbd_dev = true; >>> module_param(kbd_dev, bool, 0); >> I have no preference here, either way works for me >> Juergen, what do you think about the above? > I really have no preference here. What should be taken into account is > that boolean parameters don't need a value, meaning "true" in that case. > This would make no sense for "kbd_dev" as it wouldn't change the > default. Then I'll go with the diff above, e.g. boolean no_{kbd|ptr})dev > Juergen