Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752653AbdLERda (ORCPT ); Tue, 5 Dec 2017 12:33:30 -0500 Received: from mail-pf0-f175.google.com ([209.85.192.175]:33274 "EHLO mail-pf0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752415AbdLERdX (ORCPT ); Tue, 5 Dec 2017 12:33:23 -0500 X-Google-Smtp-Source: AGs4zMYBTjzBJwACwHwNMIRXC5xRLSp5gdfZ4sclQF1nU7+20SuRA0b4c1t79B3OXPZ0aNGrHBpw6Q== Date: Tue, 5 Dec 2017 09:33:16 -0800 From: Bjorn Andersson To: Jitendra Sharma Cc: Andy Gross , Ohad Ben-Cohen , Arun Kumar Neelakantam , Chris Lew , linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: Re: [PATCH v4 1/5] soc: qcom: Introduce QMI encoder/decoder Message-ID: <20171205173316.GP28761@minitux> References: <20171130011644.9421-1-bjorn.andersson@linaro.org> <20171130011644.9421-2-bjorn.andersson@linaro.org> <6c6be375-6895-ecaf-9844-40774f6bdd5c@codeaurora.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6c6be375-6895-ecaf-9844-40774f6bdd5c@codeaurora.org> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 804 Lines: 28 On Fri 01 Dec 01:10 PST 2017, Jitendra Sharma wrote: > Hi Bjorn, > Hi Jitendra, > On 11/30/2017 6:46 AM, Bjorn Andersson wrote: > > +static int qmi_calc_min_msg_len(struct qmi_elem_info *ei_array, > > + int level) > > +{ > > + int min_msg_len = 0; > min_msg_len should be u32 as it would not be negative IMHO all these sizes should be size_t and there are a few places where we should add "const" specifier to pointers. But I refrained from "fixing" these up in an effort to keep things as close to the downstream implementation as possible. If Andy agrees I'm hoping that we can take this version and then follow up with a separate patch, making the review more explicit and make it easier to track down any potential regressions from such a change. Thank you for the review! Regards, Bjorn