From patchwork Tue Jul 3 19:14:57 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Hellstrom X-Patchwork-Id: 10505015 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 445EC601D3 for ; Tue, 3 Jul 2018 19:17:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3446428C60 for ; Tue, 3 Jul 2018 19:17:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2871028C7F; Tue, 3 Jul 2018 19:17:35 +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=-5.2 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 24B4028C60 for ; Tue, 3 Jul 2018 19:17:34 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0F32C6E8E9; Tue, 3 Jul 2018 19:16:54 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from NAM05-BY2-obe.outbound.protection.outlook.com (mail-eopbgr710087.outbound.protection.outlook.com [40.107.71.87]) by gabe.freedesktop.org (Postfix) with ESMTPS id 64ED16E8DF for ; Tue, 3 Jul 2018 19:16:52 +0000 (UTC) Received: from fedoratest.localdomain (155.4.205.56) by DM6PR05MB4587.namprd05.prod.outlook.com (2603:10b6:5:9f::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.930.11; Tue, 3 Jul 2018 19:16:49 +0000 From: Thomas Hellstrom To: dri-devel@lists.freedesktop.org Subject: [PATCH -next 12/15] drm/vmwgfx: Improve on host message error messages Date: Tue, 3 Jul 2018 21:14:57 +0200 Message-Id: <20180703191500.2374-13-thellstrom@vmware.com> X-Mailer: git-send-email 2.18.0.rc1 In-Reply-To: <20180703191500.2374-1-thellstrom@vmware.com> References: <20180703191500.2374-1-thellstrom@vmware.com> MIME-Version: 1.0 X-Originating-IP: [155.4.205.56] X-ClientProxiedBy: DM5PR21CA0042.namprd21.prod.outlook.com (2603:10b6:3:ed::28) To DM6PR05MB4587.namprd05.prod.outlook.com (2603:10b6:5:9f::24) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b2b7742f-5f0a-4a51-0bd2-08d5e119875f X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(5600053)(711020)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060)(7193020); SRVR:DM6PR05MB4587; X-Microsoft-Exchange-Diagnostics: 1; DM6PR05MB4587; 3:BvX+aetI5+wqPWdRjssDo1w2wFELBwPgRHieGo5DJyiVxl/XSUchwpE5tvHLBaE9ngMuBpXaEKgq6ljSqeCqS2t/DRjXBGf4IK5ncwMoj8z3v58lD76b3VXv6pljYZih92mTXUEWj3nKtpszkfoIMiD2UoU6BMWMEJjRgS0LvQpMdLwU8R3WTMuhSwHiMke4N2DwGMfDfaAMJgsg73NF8kxTPQQ8ZK2GlcpMkhtV9DmuAK8pvM4430qwR+L62Wrv; 25:V5Mv3wgUFmfOIa85SPqmdeGc64bKYrNGzJK24bCUdG/2GgtK76vcSqTK3TSDNEETJ01gXB/5JXFea+AifYx+vST/xgqUAlvrRcBSbfl3pYnQvJYJu3IQkGfSIr7GEKLsYb6RhGtq3eH8h3942+cwp7gR5edIClb8TxAf3qOdRub7LFNgwoITg6nr7vKzhrYMSV8vOh3pb3I0XfHdCEHS2tVOyRDsab31rGkGU+DtB8IulohEkMJOIoG7yBWqraTNnVV8MbcTotRcH7suXnuJQKxBfCZS6Kq6zksO4lc/DCdJixtmQl6W+Mp0OfT3L9yogQfnKB2HrM3eMI+pwbN//w==; 31:u80IGrWmoWZaio6L82FxznhlwPYaCbCH+l6TKOuUwJl2EZK7zo0jN7fH76HrZxX5u4Y+eAqyLmYTFU2YmikE8D5CFOn4MuNExDUIu8Qkn93t0OrhOBqnFpcpjFCn+sSU96jKjHLcUJyMTWnrbZadPVUB+bRdIqgiMrGTN3DNprwVKCPBeslfJ7oRhM/hxucucvRGgjziTX5+K3gWh1NwT1X4IiQ6xtJUSPMitxxCzlQ= X-MS-TrafficTypeDiagnostic: DM6PR05MB4587: X-LD-Processed: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0,ExtAddr X-Microsoft-Exchange-Diagnostics: 1; DM6PR05MB4587; 20:CTwCoKGbElZvyjnaure0Hga5HQEEQInl4DrwDe7asaGvh/kKbe/SS1gPl7evnfqz6t9hf56hhy4owBAJ/dtiW9aGT80Tc0af2dskEJQACaH1HRbcAfO90Tjjde5lP/OIi9RfjNx5gG80Z7dnCCPr0NmA9NHG7AviSFnh6gmzj5ecgnzYatRgEQcw21OboSmjU4jawlfRr8LRW4dVE6ex7StfQB1AywFWKLgMDzY/COQ/+gOUalegmzpevvIaj4zzdz1HTAHs8OwHQzL0jwf+P8NIc+BhSych7gBAw2Ubz/hSQfA5ygFnxwapf1J4UwqK6TRQDpdKpUrrr+vOwU34L7ot1XPwA65abnzTbJ/TwHxyHdhtPM8FRTJSWSvkersUC5rnFZI8k9Md+S2Rd8GpwHnQkjrI4T26MTLdcm4myRsTlp7uPmu1ydDlhLKKKonE38Yq4antb6pWREuymAZszROuTuWNH60hQoJ0k/C9P7oPNPzBu9HTuNBORFA99PL0; 4:a8CtwYXD6kaKiveXZuvrTg4+GCfPArMYHZt++lG6BPJDRG+IxYk5yPGsa6qzO5NOcn6cRFqbYuvFl7coRV8odeHWv0cxrOa6wqKYibBWqPCk8h0ZFVPYTudaokUWskcHfA6iSL0bB+3+b5EpLr/SlbLPf3vx7olBwLeWtLXe+oNmc5nwQYLtW0BoX2+iM01nkdHhyuQoF8UZA8OZW7EP3QaZY5niPHznWYNZY2s5w/gb8dSXBTHiI+rF5l3MJhJKDLL4+WFuplv25GkzJWziXEiZBRP4ND3Om1pMKKBvoywoCVEtgsV2T0wJ/DOOKHet X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(61668805478150); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3002001)(10201501046)(3231254)(944501410)(52105095)(93006095)(93001095)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011)(7699016); SRVR:DM6PR05MB4587; BCL:0; PCL:0; RULEID:; SRVR:DM6PR05MB4587; X-Forefront-PRVS: 0722981D2A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(136003)(366004)(39860400002)(396003)(376002)(346002)(199004)(189003)(2361001)(53936002)(76176011)(68736007)(52116002)(51416003)(15650500001)(47776003)(26005)(2351001)(50226002)(16526019)(97736004)(86362001)(386003)(2906002)(6506007)(66066001)(186003)(316002)(16586007)(48376002)(446003)(6486002)(50466002)(14444005)(11346002)(2616005)(1076002)(956004)(6116002)(6512007)(476003)(81166006)(8676002)(81156014)(36756003)(3846002)(5660300001)(486006)(107886003)(106356001)(305945005)(25786009)(7736002)(4326008)(478600001)(6916009)(105586002)(6666003)(8936002); DIR:OUT; SFP:1101; SCL:1; SRVR:DM6PR05MB4587; H:fedoratest.localdomain; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: vmware.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM6PR05MB4587; 23:qENzEY8rMkg3CF6jqQFV5hpB7ISX7ga4DmvvHElKn?= =?us-ascii?Q?RNMC4WGzrX6TwcQUdPnVu8O+DZwwDFMnXzxXLqPRI+vSx4GVpPWwYfy8vGWj?= =?us-ascii?Q?Hck0FB6IbIwGn/A+1WwGlyQfZnNVuHZUDOmHFeOEnfctQDlJ8gYdovuhWZIW?= =?us-ascii?Q?nyvwey+OMKb24L6EeUf3enkIi+b44xUrhRFVINtlvNsnd2j+3QBqgOx1VcKS?= =?us-ascii?Q?QuDXyEHfmyPprlKsWhhMdCeU9O0UkSVLmAyBRct1AHhx6NEnr8Ss/YC6hrnl?= =?us-ascii?Q?jfWlCDi6psklBpDBuA18eDti9KePdZuJhqEBPFoIlcHVBfVxGnOeJXQ+u+C3?= =?us-ascii?Q?j5Cru/1FXA61NrewDt7jZft5pHSMSqbeT7FDf5l8ykvqmaE8OVkM6E1l5dPC?= =?us-ascii?Q?7ZHrSnI57QSKwjkRQw0D44oWLUPMvmMdvX7toL/IGmbKvax0rMKcugr3EI9B?= =?us-ascii?Q?2sxkUBcqlMQGbtYpGfHJF4O4AYtRuHr3gYFr+X/OcD+J5OslmHwh/eCN77y+?= =?us-ascii?Q?gvcg6AMZdyifM9CZtb+acPrBNVYm8e4op2gsYrEW7xLWGat9mq+OMx6mX1ds?= =?us-ascii?Q?GBdb+1UM1UdDlNeZf9JZ3z8LefUN6Z8S79EcgoM09N7oStt7xFCko/Sag6qD?= =?us-ascii?Q?Y1aWsw+khpYPdZ0OZEWlbIDPkdUxGzbXSWsrEUKfTJSu3BLJllGp+lziqksv?= =?us-ascii?Q?e5cuiq4Jcf9711rDiPzXGxVJ91Z/YKAUI+r2Y6MqFLY3M38J7bq8pbJ09XRb?= =?us-ascii?Q?NOYd0DGq853GplUwbgkf5DGnnO3sl1AEtMrlpNnh7L9gIgrCkNWjNO54K5K9?= =?us-ascii?Q?p70RxCwAUL4wVa2UoYv2FxYnnpAbbLuOVdpLkYXo5l88+PnY91Sr0MpE5s/m?= =?us-ascii?Q?MXV7l7oDqRfWEsvURFMO1dvXmo9FDx30t35DqvW0q/y4vL0FyNDH0bdLBE3o?= =?us-ascii?Q?Ny7RiIKJTibSmt8HnjqHO+lbBqKpsiJtE4W5/row2Kbo9MHXIQzEOZegpgLc?= =?us-ascii?Q?Axfhkuj6QGvVslO4Orgjy2492qt3WIC/AUBLQR/7CkDtZR4W9mYXaSmAldPF?= =?us-ascii?Q?SUt0IRrtxzYOYOSnbmKkDl25WKuJ5vzTmrVKn0+mJ6BeAnsvE6kUZeLgcd6L?= =?us-ascii?Q?0vxl60k7eWUo6UhudDmxYbe3KCpoQ3OZe8HA+S0jPS6DgE9eRSDp3EU8g6r/?= =?us-ascii?Q?nVfZukdaviUkLBmxtwvLLBDKQia4AUSw4TxNb5VlNigcqVRnDltyBig8ojKa?= =?us-ascii?Q?UWIQMkSWx1tIrGQnHYbxVxCM2EGacy+ErlCT341Ql1jBxvDi+f9rLGg0OgLZ?= =?us-ascii?B?UT09?= X-Microsoft-Antispam-Message-Info: 5Un2LEY51gZOaanN2BwTErvPBqLv7LySfridJMe7H/7EUYmkAohgRWoGDjWgYKIFqt9wCRUAx1IL4XEmgSG57P0zFeyyvManjB9ULCNaJEDjtK3gnlQMmQZso0p3aR201iwqp8tKdQkY+piH8/kShJT8QqlT4EqZIKQnFwyz+pHULB8n44Jt73D6quPd9+8UrJNCnrhrmIIgIJaj9UuHh33+iFljzhdgKHMESwrONVw/U4ghrxJagPhToPpECXQ9kfYtzVMBub04WY4+IDBsWuG6nOoAg8D+/ZxUjC0QOkZSBDhzhL5c3CZf9lSwUzEWwKCv8oKhtst5YSm+JaKh/Oxu7LDbOuCmGKw/ciprHMo= X-Microsoft-Exchange-Diagnostics: 1; DM6PR05MB4587; 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LMlB25KUEF2riM3x66NM5; 20:bxIjTdA2WeQv0o7BkxqwXxaRGv0vguOVDUSP72Xq06JbQKiZskrb+vVIvLotoR/qMRAcg6RVCllZOORb/b5fpWQn24fF6ajHxoO3PD3k9Eq1DOnDJ+Zw/P3E0kdKTPNAj55b4wFiRgTOshJt/p3zb0fsE33WqWCe+c2T5+sYmJE= X-OriginatorOrg: vmware.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jul 2018 19:16:49.7443 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: b2b7742f-5f0a-4a51-0bd2-08d5e119875f X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR05MB4587 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Hellstrom , linux-graphics-maintainer@vmware.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Make sure the error messages are a bit more descriptive, so that a log reader may understand what's gone wrong. Signed-off-by: Thomas Hellstrom Reviewed-by: Brian Paul Reviewed-by: Sinclair Yeh --- drivers/gpu/drm/vmwgfx/vmwgfx_msg.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_msg.c b/drivers/gpu/drm/vmwgfx/vmwgfx_msg.c index 21d746bdc922..a72268e97042 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_msg.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_msg.c @@ -234,7 +234,7 @@ static int vmw_recv_msg(struct rpc_channel *channel, void **msg, if ((HIGH_WORD(ecx) & MESSAGE_STATUS_SUCCESS) == 0 || (HIGH_WORD(ecx) & MESSAGE_STATUS_HB) == 0) { - DRM_ERROR("Failed to get reply size\n"); + DRM_ERROR("Failed to get reply size for host message.\n"); return -EINVAL; } @@ -245,7 +245,7 @@ static int vmw_recv_msg(struct rpc_channel *channel, void **msg, reply_len = ebx; reply = kzalloc(reply_len + 1, GFP_KERNEL); if (!reply) { - DRM_ERROR("Cannot allocate memory for reply\n"); + DRM_ERROR("Cannot allocate memory for host message reply.\n"); return -ENOMEM; } @@ -338,7 +338,8 @@ int vmw_host_get_guestinfo(const char *guest_info_param, msg = kasprintf(GFP_KERNEL, "info-get %s", guest_info_param); if (!msg) { - DRM_ERROR("Cannot allocate memory to get %s", guest_info_param); + DRM_ERROR("Cannot allocate memory to get guest info \"%s\".", + guest_info_param); return -ENOMEM; } @@ -374,7 +375,7 @@ int vmw_host_get_guestinfo(const char *guest_info_param, out_open: *length = 0; kfree(msg); - DRM_ERROR("Failed to get %s", guest_info_param); + DRM_ERROR("Failed to get guest info \"%s\".", guest_info_param); return -EINVAL; } @@ -403,7 +404,7 @@ int vmw_host_log(const char *log) msg = kasprintf(GFP_KERNEL, "log %s", log); if (!msg) { - DRM_ERROR("Cannot allocate memory for log message\n"); + DRM_ERROR("Cannot allocate memory for host log message.\n"); return -ENOMEM; } @@ -422,7 +423,7 @@ int vmw_host_log(const char *log) vmw_close_channel(&channel); out_open: kfree(msg); - DRM_ERROR("Failed to send log\n"); + DRM_ERROR("Failed to send host log message.\n"); return -EINVAL; }