Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp4037751imw; Mon, 18 Jul 2022 20:42:54 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sm9fwcAnP5hQX0aGlCqQycRN7W5kXFeyUgY3s8AhaPWcbkrMvVx6Gnl2+c0Lby3hFaEHSL X-Received: by 2002:a17:90b:3907:b0:1f0:386e:c0ee with SMTP id ob7-20020a17090b390700b001f0386ec0eemr3252860pjb.141.1658202174735; Mon, 18 Jul 2022 20:42:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658202174; cv=none; d=google.com; s=arc-20160816; b=E/j5JzDI8Qlamom4q7BjvUd1ezBhzcD4Kmqz3j6/X0OWZaqBuEQkyvHzZ9IpuwwBon ifbJpMl+P9eYdE79CE0wCcuMVUQRnprH6pavYyDOJ2apG2tkkhtrOttR7qXn8Vh8pe80 hDsl4oI7oP3NeRUSaqj2WlaabH82jxug/++3fGfVOB/cMMElpGqqaohxFrfjAQijW3Ty cKqnxlx8/79jednLtvUD+7Ly0RKF6QkdaEkJnS+h9iDsgEYJtK5wSyPllByyel7YqD2e F1KODRA98KKIMY72QKOYAAhSPKiyDhTvCnnPg89LDRXfHDzGyEmP1PQeVIC5YIsHrnYH pgTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version:dkim-signature:dkim-signature; bh=pkvLznJmCOLzAgbLSLBHczbN4GBylXyt4/rPo9JuOpI=; b=xS6M7VcsEeUjKXVlOiU/kZirdHlsL0K2jmhR6NSuQ2xmw0oH0pwG3P13UQ17gjzo6q H/pG92sILVzzcn1H3kSE0B8uz3wsfKCY3ZEXFCVWDnYzirT85o5vVlhg6DrJgxGPfJ2Y 2ZpTrZyAIPN4YYeAsGW+wEfiwAV/r1z7nEXgjrdWK2rOUlBdfVcO6X42wqXG9s2TSUO2 qawN2GvXamNwAgL9EXRV4L7M09ASWQ6108zQXj9DTQXX8m/UMeljpb7l3xUJD0g5oD3h VFr5n1p9NCwjjd443prWzwJPbscsVbXAfYOQRM4iwLMxlR024kkH9t9Lp2e74XNgnZso 48dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=MGchgFos; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=V619nqHK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z196-20020a6333cd000000b0041610ee2f17si16339834pgz.261.2022.07.18.20.42.39; Mon, 18 Jul 2022 20:42:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=MGchgFos; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=V619nqHK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234591AbiGSDbk (ORCPT + 99 others); Mon, 18 Jul 2022 23:31:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37200 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234220AbiGSDbi (ORCPT ); Mon, 18 Jul 2022 23:31:38 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 550E325594; Mon, 18 Jul 2022 20:31:35 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 6075B33C42; Tue, 19 Jul 2022 03:31:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1658201493; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pkvLznJmCOLzAgbLSLBHczbN4GBylXyt4/rPo9JuOpI=; b=MGchgFosaGDK72KdXjSY5BIPeOB8KC4hJ6dwbcxioiDecPsK2/rdJL/Ohb+Wa6/sB6MlhA W3Q7BJoV6PUQvG8pp/beXHFqGEsyfI5PAb6jM8yB2hp7eoIwPc3jn0QZkZw1sLuUIjdGA4 8qLFBEIIvtptMGdyEqaOXTkakqWAgYc= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1658201493; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pkvLznJmCOLzAgbLSLBHczbN4GBylXyt4/rPo9JuOpI=; b=V619nqHKSDQvBuzTYB9E+4Ung+dBq8Rx88j8rXQ8wZ2HbMcjZgluOkldV6KyyCGWAPQzFm MRj8JqnhnScrlaDg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id D230213754; Tue, 19 Jul 2022 03:31:31 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id t1GFKZMl1mKGWQAAMHmgww (envelope-from ); Tue, 19 Jul 2022 03:31:31 +0000 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.100.31\)) Subject: Re: [PATCH -next] bcache: Fix spelling mistakes and cleanup code From: Coly Li In-Reply-To: <20220715071533.2729413-1-williamsukatube@163.com> Date: Tue, 19 Jul 2022 10:50:24 +0800 Cc: Kent Overstreet , linux-bcache@vger.kernel.org, linux-kernel@vger.kernel.org, William Dean , Hacash Robot Content-Transfer-Encoding: quoted-printable Message-Id: References: <20220715071533.2729413-1-williamsukatube@163.com> To: williamsukatube@163.com X-Mailer: Apple Mail (2.3696.100.31) X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > 2022=E5=B9=B47=E6=9C=8815=E6=97=A5 15:15=EF=BC=8Cwilliamsukatube@163.com= =E5=86=99=E9=81=93=EF=BC=9A >=20 > From: William Dean >=20 > First, fix follow spelling misktakes: > automatical =3D=3D> automatic > individial =3D=3D> around > embeddded =3D=3D> embedded > addionally =3D=3D> addtionally > unncessary =3D=3D> unnecessary > definitly =3D=3D> definitely > Second, delete extra space or tab where > appropriate to make code format more standardized. >=20 > Reported-by: Hacash Robot > Signed-off-by: William Dean Hi William, It should be better to split this patch into 2 parts, one is for typo = fixes, one is for extra space or tab fixes. Then it can be more = convenient for me to review and maintain. And BTW, addionally =3D=3D> addtionally, I guess you meant = =E2=80=98additionally=E2=80=99, wasn=E2=80=99t it? Thanks. Coly Li > --- > drivers/md/bcache/bcache.h | 2 +- > drivers/md/bcache/bset.h | 2 +- > drivers/md/bcache/btree.c | 6 +++--- > drivers/md/bcache/btree.h | 2 +- > drivers/md/bcache/journal.c | 2 +- > drivers/md/bcache/request.c | 5 ++--- > drivers/md/bcache/stats.c | 2 +- > drivers/md/bcache/super.c | 2 +- > drivers/md/bcache/writeback.c | 2 +- > drivers/md/bcache/writeback.h | 2 +- > 10 files changed, 13 insertions(+), 14 deletions(-) >=20 > diff --git a/drivers/md/bcache/bcache.h b/drivers/md/bcache/bcache.h > index 2acda9cea0f9..2b35c0a14d4d 100644 > --- a/drivers/md/bcache/bcache.h > +++ b/drivers/md/bcache/bcache.h > @@ -635,7 +635,7 @@ struct cache_set { > struct bkey gc_done; >=20 > /* > - * For automatical garbage collection after writeback completed, = this > + * For automatic garbage collection after writeback completed, = this > * varialbe is used as bit fields, > * - 0000 0001b (BCH_ENABLE_AUTO_GC): enable gc after writeback > * - 0000 0010b (BCH_DO_AUTO_GC): do gc after writeback > diff --git a/drivers/md/bcache/bset.h b/drivers/md/bcache/bset.h > index d795c84246b0..76f75bbcb731 100644 > --- a/drivers/md/bcache/bset.h > +++ b/drivers/md/bcache/bset.h > @@ -45,7 +45,7 @@ > * 4 in memory - we lazily resort as needed. > * > * We implement code here for creating and maintaining auxiliary = search trees > - * (described below) for searching an individial bset, and on top of = that we > + * (described below) for searching an individual bset, and on top of = that we > * implement a btree iterator. > * > * BTREE ITERATOR: > diff --git a/drivers/md/bcache/btree.c b/drivers/md/bcache/btree.c > index e136d6edc1ed..3d9fec07e862 100644 > --- a/drivers/md/bcache/btree.c > +++ b/drivers/md/bcache/btree.c > @@ -154,7 +154,7 @@ void bch_btree_node_read_done(struct btree *b) > /* > * c->fill_iter can allocate an iterator with more memory space > * than static MAX_BSETS. > - * See the comment arount cache_set->fill_iter. > + * See the comment around cache_set->fill_iter. > */ > iter =3D mempool_alloc(&b->c->fill_iter, GFP_NOIO); > iter->size =3D b->c->cache->sb.bucket_size / = b->c->cache->sb.block_size; > @@ -2529,8 +2529,8 @@ int __bch_btree_map_nodes(struct btree_op *op, = struct cache_set *c, > } >=20 > int bch_btree_map_keys_recurse(struct btree *b, struct btree_op *op, > - struct bkey *from, = btree_map_keys_fn *fn, > - int flags) > + struct bkey *from, btree_map_keys_fn *fn, > + int flags) > { > int ret =3D MAP_CONTINUE; > struct bkey *k; > diff --git a/drivers/md/bcache/btree.h b/drivers/md/bcache/btree.h > index 1b5fdbc0d83e..b46bf6268aca 100644 > --- a/drivers/md/bcache/btree.h > +++ b/drivers/md/bcache/btree.h > @@ -54,7 +54,7 @@ > * Btree nodes never have to be explicitly read in; = bch_btree_node_get() handles > * this. > * > - * For writing, we have two btree_write structs embeddded in struct = btree - one > + * For writing, we have two btree_write structs embedded in struct = btree - one > * write in flight, and one being set up, and we toggle between them. > * > * Writing is done with a single function - bch_btree_write() really = serves two > diff --git a/drivers/md/bcache/journal.c b/drivers/md/bcache/journal.c > index e5da469a4235..c7f6d2611037 100644 > --- a/drivers/md/bcache/journal.c > +++ b/drivers/md/bcache/journal.c > @@ -790,7 +790,7 @@ static void journal_write_unlocked(struct closure = *cl) >=20 > atomic_long_add(sectors, &ca->meta_sectors_written); >=20 > - bio_reset(bio, ca->bdev, REQ_OP_WRITE |=20 > + bio_reset(bio, ca->bdev, REQ_OP_WRITE | > REQ_SYNC | REQ_META | REQ_PREFLUSH | REQ_FUA); > bio->bi_iter.bi_sector =3D PTR_OFFSET(k, i); > bio->bi_iter.bi_size =3D sectors << 9; > diff --git a/drivers/md/bcache/request.c b/drivers/md/bcache/request.c > index f2c5a7e06fa9..ceba536e0880 100644 > --- a/drivers/md/bcache/request.c > +++ b/drivers/md/bcache/request.c > @@ -338,7 +338,6 @@ unsigned int bch_get_congested(const struct = cache_set *c) > return 0; >=20 > i +=3D CONGESTED_MAX; > - > if (i > 0) > i =3D fract_exp_two(i, 6); >=20 > @@ -1326,8 +1325,8 @@ static int flash_dev_ioctl(struct bcache_device = *d, fmode_t mode, >=20 > void bch_flash_dev_request_init(struct bcache_device *d) > { > - d->cache_miss =3D = flash_dev_cache_miss; > - d->ioctl =3D flash_dev_ioctl; > + d->cache_miss =3D flash_dev_cache_miss; > + d->ioctl =3D flash_dev_ioctl; > } >=20 > void bch_request_exit(void) > diff --git a/drivers/md/bcache/stats.c b/drivers/md/bcache/stats.c > index 68b02216033d..983d16822e53 100644 > --- a/drivers/md/bcache/stats.c > +++ b/drivers/md/bcache/stats.c > @@ -11,7 +11,7 @@ > #include "sysfs.h" >=20 > /* > - * We keep absolute totals of various statistics, and addionally a = set of three > + * We keep absolute totals of various statistics, and addtionally a = set of three > * rolling averages. > * > * Every so often, a timer goes off and rescales the rolling averages. > diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c > index 3563d15dbaf2..aca27386cca2 100644 > --- a/drivers/md/bcache/super.c > +++ b/drivers/md/bcache/super.c > @@ -686,6 +686,7 @@ int bch_prio_write(struct cache *ca, bool wait) >=20 > ca->prio_last_buckets[i] =3D ca->prio_buckets[i]; > } > + > return 0; > } >=20 > @@ -2663,7 +2664,6 @@ static ssize_t register_bcache(struct kobject = *k, struct kobj_attribute *attr, > return ret; > } >=20 > - > struct pdev { > struct list_head list; > struct cached_dev *dc; > diff --git a/drivers/md/bcache/writeback.c = b/drivers/md/bcache/writeback.c > index 3f0ff3aab6f2..bd83a33b8a2f 100644 > --- a/drivers/md/bcache/writeback.c > +++ b/drivers/md/bcache/writeback.c > @@ -238,7 +238,7 @@ static void update_writeback_rate(struct = work_struct *work) > /* > * If the whole cache set is idle, set_at_max_writeback_rate() > * will set writeback rate to a max number. Then it is > - * unncessary to update writeback rate for an idle cache set > + * unnecessary to update writeback rate for an idle cache set > * in maximum writeback rate number(s). > */ > if (atomic_read(&dc->has_dirty) && dc->writeback_percent && > diff --git a/drivers/md/bcache/writeback.h = b/drivers/md/bcache/writeback.h > index 31df716951f6..37f66bea522f 100644 > --- a/drivers/md/bcache/writeback.h > +++ b/drivers/md/bcache/writeback.h > @@ -69,7 +69,7 @@ static inline int offset_to_stripe(struct = bcache_device *d, > } >=20 > /* > - * Here offset is definitly smaller than INT_MAX, > + * Here offset is definitely smaller than INT_MAX, > * return it as int will never overflow. > */ > return offset; > --=20 > 2.25.1 >=20