From patchwork Fri Jan 19 00:49:55 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 10174397 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 77C54602B8 for ; Fri, 19 Jan 2018 00:50:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6760628446 for ; Fri, 19 Jan 2018 00:50:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5C00C284AA; Fri, 19 Jan 2018 00:50:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id ED06E28446 for ; Fri, 19 Jan 2018 00:50:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755256AbeASAuL (ORCPT ); Thu, 18 Jan 2018 19:50:11 -0500 Received: from mail-pf0-f193.google.com ([209.85.192.193]:42176 "EHLO mail-pf0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755055AbeASAuE (ORCPT ); Thu, 18 Jan 2018 19:50:04 -0500 Received: by mail-pf0-f193.google.com with SMTP id b25so69865pfd.9; Thu, 18 Jan 2018 16:50:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=i+UW62ra/G9fOOl7x93Ap9sFtrETQKXEHowDwv/i8AI=; b=ARMmYw/oRPcgyi+tK1GW5G4njdYLA+VAw3VAw09BV2fUdIHhbtsIdHaiOXiR0Oy/LH rhA4WI4e9N5LQpJvjQGz19fyLOHAErp/u3IgOcw3aoc36ADWXwBIQukOxRZcRHcca0/A 7a/c5m04QWZU4THiNrTEePbmzr1QQFmq2gccmKxkZ7BGVV1LXaqfiG4l0BpDzuUdbbh1 U7A/OjSkudcWBYGj+kuxuHGIovy0XGXLBxXq861DZ1NdyUfqieXQkEMaWqGt4w6DiwCR Py7MNX1WRvKvmTifmGJ+yLZJqGcPgd5A/X4etWgo5me4OBIeoDZ2FwjiGuMn+rR1Wh+S 4CxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=i+UW62ra/G9fOOl7x93Ap9sFtrETQKXEHowDwv/i8AI=; b=gimyMah3btrI747yxyti2tJ4CbMR+nawhedMZiJYaj9kzLz7p2yvRQimb6opoeAa8+ Cgjlmb0lm0wc11MWYdGh0HpeLuy2xzg/nw3rq8Buy93sjdlTerEesfDrYg7FDstzRLEf rRVrAA0KsMgGPNtT60tKNamCoJAWFK+D4BA17ot4PJ8BEpaCczguVj0+5kzP8JcwT5ya alQpIiHdddoDo7o935CRvylTjatbJr6Pezi/Lujxa5CqzhET9M3/lAr2mb3tMigEf8cp p4214zpYjlsz6JDlCVbqyVrKm0BiIB68QRnkTjvnub6lcrECiANyRFctoP4N2VFXAqMJ 9jKQ== X-Gm-Message-State: AKwxyte6x6ryQZ2d8d4DIjAMfN7Tbh3lKIoVfjIXvwcMLcPS0EuzLOTi 9NgjhxMi4a7ufKjZ06jpfuI= X-Google-Smtp-Source: ACJfBou1VSz/Fug1ohkjz+QbhT9QC9L7MZW0QpqtaF5m1/XH8ToPda6kOOpJ4+X9wlifhTpG0ZBShA== X-Received: by 2002:a17:902:8bc5:: with SMTP id r5-v6mr657718plo.213.1516323003262; Thu, 18 Jan 2018 16:50:03 -0800 (PST) Received: from dtor-ws.mtv.corp.google.com ([2620:0:1000:1611:da80:8749:c06f:9515]) by smtp.gmail.com with ESMTPSA id t80sm12540937pgb.88.2018.01.18.16.50.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Jan 2018 16:50:01 -0800 (PST) From: Dmitry Torokhov To: Benjamin Tissoires , Lyude Paul , Damjan Georgievski Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, Andrew Duggan Subject: [PATCH 3/3] Input: synaptics-rmi4 - log when we create a guest serio port Date: Thu, 18 Jan 2018 16:49:55 -0800 Message-Id: <20180119004955.247190-4-dmitry.torokhov@gmail.com> X-Mailer: git-send-email 2.16.0.rc1.238.g530d649a79-goog In-Reply-To: <20180119004955.247190-1-dmitry.torokhov@gmail.com> References: <20180119004955.247190-1-dmitry.torokhov@gmail.com> Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP To ease analyzing boot behavior from logs, let's log when we are about to register the pass-through serio port. Also, let's drop "Synaptics" prefix from the port name, as RMI4 is good enough indicator already, and having the prefix means that the name does not fit into serio->name field. While at it move from hard-coded seio->phys to one mentioning the sensor ID (such as "rmi4-00.fn03/serio0"). Signed-off-by: Dmitry Torokhov Reviewed-by: Lyude Paul --- drivers/input/rmi4/rmi_f03.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/input/rmi4/rmi_f03.c b/drivers/input/rmi4/rmi_f03.c index 7ccbb370a9a81..88822196d6b72 100644 --- a/drivers/input/rmi4/rmi_f03.c +++ b/drivers/input/rmi4/rmi_f03.c @@ -184,14 +184,15 @@ static int rmi_f03_register_pt(struct f03_data *f03) serio->close = rmi_f03_pt_close; serio->port_data = f03; - strlcpy(serio->name, "Synaptics RMI4 PS/2 pass-through", - sizeof(serio->name)); - strlcpy(serio->phys, "synaptics-rmi4-pt/serio1", - sizeof(serio->phys)); + strlcpy(serio->name, "RMI4 PS/2 pass-through", sizeof(serio->name)); + snprintf(serio->phys, sizeof(serio->phys), "%s/serio0", + dev_name(&f03->fn->dev)); serio->dev.parent = &f03->fn->dev; f03->serio = serio; + printk(KERN_INFO "serio: %s port at %s\n", + serio->name, dev_name(&f03->fn->dev)); serio_register_port(serio); return 0;