Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756065AbbDOSf0 (ORCPT ); Wed, 15 Apr 2015 14:35:26 -0400 Received: from seldrel01.sonyericsson.com ([212.209.106.2]:19046 "EHLO seldrel01.sonyericsson.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752040AbbDOSfX (ORCPT ); Wed, 15 Apr 2015 14:35:23 -0400 Date: Wed, 15 Apr 2015 11:35:16 -0700 From: Bjorn Andersson To: Akinobu Mita CC: Vinayak Holikatti , "James E.J. Bottomley" , Mark Brown , "linux-scsi@vger.kernel.org" , LKML , "linux-arm-msm@vger.kernel.org" Subject: Re: [PATCH 2/5] ufs: Rename of regulator_set_optimum_mode Message-ID: <20150415183516.GC29061@sonymobile.com> References: <1423712131-23795-1-git-send-email-bjorn.andersson@sonymobile.com> <1423712131-23795-3-git-send-email-bjorn.andersson@sonymobile.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.22 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1300 Lines: 36 On Tue 14 Apr 05:11 PDT 2015, Akinobu Mita wrote: > 2015-02-12 12:35 GMT+09:00 Bjorn Andersson : > > The function regulator_set_optimum_mode() is changing name to > > regulator_set_load(), so update the code accordingly. Also cleaned up > > ufshcd_config_vreg_load() while touching the code. > > > > Signed-off-by: Bjorn Andersson [..] > > static inline int ufshcd_config_vreg_hpm(struct ufs_hba *hba, > > struct ufs_vreg *vreg) > > { > > - if (!vreg) > > - return 0; > > - > > return ufshcd_config_vreg_load(hba->dev, vreg, vreg->max_uA); > > } > > I tried this patch and it caused kernel null pointer dereference with > 'verg->max_uA' when vreg == NULL. So you can't simply move !vreg check here > into ufshcd_config_vreg_load(). Akinobu-san, you're correct, sorry for missing that (and in essence reverting your commit). Looks like Linus merged the fix on master, so I will send out a fixup. Regards, Bjorn -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/