Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753359AbbKZTqU (ORCPT ); Thu, 26 Nov 2015 14:46:20 -0500 Received: from smtprelay0085.hostedemail.com ([216.40.44.85]:34102 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751457AbbKZTqS (ORCPT ); Thu, 26 Nov 2015 14:46:18 -0500 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::::::,RULES_HIT:41:355:379:541:599:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1539:1593:1594:1711:1714:1730:1747:1777:1792:2393:2559:2562:2828:3138:3139:3140:3141:3142:3350:3622:3866:3867:3868:3871:4321:5007:6261:8957:10004:10400:10848:11026:11658:11914:12043:12048:12296:12438:12517:12519:12534:12740:13069:13161:13229:13311:13357:13972:14659:21080:30054:30064:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: quilt74_199cd24bb9f1f X-Filterd-Recvd-Size: 1730 Message-ID: <1448567174.18647.19.camel@perches.com> Subject: Re: [PATCH 2/3] arcmsr: Split dma resource allocation to a new function From: Joe Perches To: Ching Huang , thenzl@redhat.com, hch@infradead.org, jbottomley@parallels.com, dan.carpenter@oracle.com, agordeev@redhat.com, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, hare@suse.de, jthumshirn@suse.de Cc: hch@lst.de Date: Thu, 26 Nov 2015 11:46:14 -0800 In-Reply-To: <1448538075.10768.47.camel@Centos6.3-64> References: <1448538075.10768.47.camel@Centos6.3-64> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.16.5-1ubuntu3 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 996 Lines: 29 On Thu, 2015-11-26 at 19:41 +0800, Ching Huang wrote: > split dma resource allocation and io register assignment from get_config to a new function arcmsr_alloc_io_queue. trivia: > diff -uprN a/drivers/scsi/arcmsr/arcmsr_hba.c b/drivers/scsi/arcmsr/arcmsr_hba.c [] > +static bool arcmsr_alloc_io_queue(struct AdapterControlBlock *acb) > +{ [] > + dma_coherent = dma_alloc_coherent(&pdev->dev, acb->roundup_ccbsize, > + &dma_coherent_handle, GFP_KERNEL); > + if (!dma_coherent){ > + pr_notice("arcmsr%d: DMA allocation failed.\n", acb->host->host_no); > + return false; > + } > + memset(dma_coherent, 0, acb->roundup_ccbsize); > There is a dma_zalloc_coherent (and even more trivially) Most all of your error messages don't use periods. -- 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/