Received: by 10.213.65.68 with SMTP id h4csp864339imn; Wed, 14 Mar 2018 02:23:09 -0700 (PDT) X-Google-Smtp-Source: AG47ELsVzHIRgJMQIi/vjDkec5OFBMTy8vWyQ6ACqLng2GrxX92lE/ao9BbDMN2g8z3QC67wIwOv X-Received: by 10.99.174.66 with SMTP id e2mr3101136pgp.269.1521019389406; Wed, 14 Mar 2018 02:23:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521019389; cv=none; d=google.com; s=arc-20160816; b=vrFybOvpKVIyQtp4PpK4u+r/8fHzVRve9bKT7bY+tFnCQW/fCjx7Xx/vV9oP6I/+jA NMMp8IQnLMa/dA5bQphXLzfg1fuwXRD54PjbZ8YxKfokA2eXAX0jw4WWDrCdeL1QVT45 j0gLXf7t4X1xrlVOjRKK6ilfpZ70P4m6AxT133iCbMjx3jYTFLAQoxZiMZKC72bw7nEU sRMWLZdHPa932krAjxR62EEODRP2HVAywWevuQvyBg2gUm1JiUgkym72zLQrFLwytZ+H 0D6fsa1YnSvnBOPtZILxWg+aTYuOZ7UqS2V/od1o2t/maDofEQxOhads/CAyYdlzZoL2 W09g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=0/dXCaYE5Keaq2qgD6rtv83MpymOjT1E1xxpAazhmuM=; b=sckOWmZ7DkMIBAd+YKnKAFq8betl5d1QOOllDKBvPdswsjLAcQ3wf/VUFfhpohw4b7 eeu56CaQniY875UjSDqRtq03W0go0nFJjwR5ZZyJ7/HcWfIf2jt9NWiaFJqSI1pwT0qX nA5xaxfyHOa0SwvOj92SVN6emV7rsTMLI/a0ZwzrC00TbX4mRXpp0Vo1lZLIAtp2IDL+ j63OC6Il8hog2AekkC2OQbpumUzTgCOmagf/VRgC6z88JiuAU6yPR8ug6dunvqETmDFF fuVbR4+nVhRcteH39PnbB6QYDnTMwPF4LhLFQ4QGXMLzdtkq7OBHppaOiuplVI8VaSoM XHkg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e8si1601202pgn.116.2018.03.14.02.22.55; Wed, 14 Mar 2018 02:23:09 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751840AbeCNJVx (ORCPT + 99 others); Wed, 14 Mar 2018 05:21:53 -0400 Received: from vegas.theobroma-systems.com ([144.76.126.164]:39812 "EHLO mail.theobroma-systems.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751696AbeCNJVu (ORCPT ); Wed, 14 Mar 2018 05:21:50 -0400 Received: from [86.59.122.178] (port=55831 helo=ju27.lan) by mail.theobroma-systems.com with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1ew2bU-0000W0-4b; Wed, 14 Mar 2018 10:21:48 +0100 Subject: Re: [PATCH v2 1/1] can: ucan: add driver for Theobroma Systems UCAN devices To: Wolfgang Grandegger Cc: Martin Elshuber , Philipp Tomsich , Marc Kleine-Budde , linux-can@vger.kernel.org, linux-kernel@vger.kernel.org References: <20180313173520.21257-1-jakob.unterwurzacher@theobroma-systems.com> <20180313173520.21257-2-jakob.unterwurzacher@theobroma-systems.com> <03024ab7-5386-3bcf-76f2-ef2e0e9e7a78@theobroma-systems.com> <68564c40-396b-9081-8534-67fe96a6fb3f@grandegger.com> From: Jakob Unterwurzacher Message-ID: Date: Wed, 14 Mar 2018 10:21:43 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <68564c40-396b-9081-8534-67fe96a6fb3f@grandegger.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 14.03.18 10:17, Wolfgang Grandegger wrote: > Counting the state changes is one thing but you should also generate > error messages for them. We do for BUS-OFF already (see below), but not for other states - will do in v3. > + /* we switched into a worse state */ > + up->can.state = new_state; > + switch (new_state) { > + case CAN_STATE_BUS_OFF: > + can_stats->bus_off++; > + can_bus_off(up->netdev); > + netdev_info(up->netdev, > + "link has gone into BUS-OFF state\n"); > + break;