Message ID | cover.1679278088.git.wqu@suse.com (mailing list archive) |
---|---|
Headers | show |
Series | btrfs: scrub: use a more reader friendly code to implement scrub_simple_mirror() | expand |
On Mon, Mar 20, 2023 at 10:12:46AM +0800, Qu Wenruo wrote: > [TODO] > > - More testing on zoned devices > Now the patchset can already pass all scrub/replace groups with > regular devices. I think I noticed some disparity in the old and new code for the zoned devices. This should be found by testing so I'd add this series to for-next and see. > - More cleanup on RAID56 path > Now RAID56 still uses some old facility, resulting things like > scrub_sector and scrub_bio can not be fully cleaned up. We can do that incrementally, as long as the raid56 scrub works the cleanups can be done later, the series changes a lot of code already. > Qu Wenruo (12): > btrfs: scrub: use dedicated super block verification function to scrub > one super block > btrfs: introduce a new helper to submit bio for scrub > btrfs: introduce a new helper to submit write bio for scrub > btrfs: scrub: introduce the structure for new BTRFS_STRIPE_LEN based > interface > btrfs: scrub: introduce a helper to find and fill the sector info for > a scrub_stripe > btrfs: scrub: introduce a helper to verify one metadata > btrfs: scrub: introduce a helper to verify one scrub_stripe > btrfs: scrub: introduce the main read repair worker for scrub_stripe > btrfs: scrub: introduce a writeback helper for scrub_stripe > btrfs: scrub: introduce error reporting functionality for scrub_stripe > btrfs: scrub: introduce the helper to queue a stripe for scrub > btrfs: scrub: switch scrub_simple_mirror() to scrub_stripe > infrastructure The whole series follows the pattern to first introduce the individual helpers that can be reviewed separately and then does the switch in one patch. As the whole scrub IO path is reworked I don't think we can do much better so clearly separating the old and new logic sounds OK. One comment I have, the functional switch in the last patch should not be mixed with deleting of the unused code. As the last patch activates code from all the previous patches it would also show up in any bisection as the cause so it would help to narrow the focus only on the real changes. There are some minor coding style issues I'll point out under the patches. I'm assuming that the scrub structure won't change again soon (the old code is from 3.x times) so let's use this opportunity to make the style most up to date.
On 2023/3/21 08:09, David Sterba wrote: > On Mon, Mar 20, 2023 at 10:12:46AM +0800, Qu Wenruo wrote: >> [TODO] >> >> - More testing on zoned devices >> Now the patchset can already pass all scrub/replace groups with >> regular devices. > > I think I noticed some disparity in the old and new code for the zoned > devices. This should be found by testing so I'd add this series to > for-next and see. Just want to be sure, if I want to further update the series (mostly style and small cleanups), I should just base all my updates on your for-next branch, right? Thanks, Qu > >> - More cleanup on RAID56 path >> Now RAID56 still uses some old facility, resulting things like >> scrub_sector and scrub_bio can not be fully cleaned up. > > We can do that incrementally, as long as the raid56 scrub works the > cleanups can be done later, the series changes a lot of code already. > >> Qu Wenruo (12): >> btrfs: scrub: use dedicated super block verification function to scrub >> one super block >> btrfs: introduce a new helper to submit bio for scrub >> btrfs: introduce a new helper to submit write bio for scrub >> btrfs: scrub: introduce the structure for new BTRFS_STRIPE_LEN based >> interface >> btrfs: scrub: introduce a helper to find and fill the sector info for >> a scrub_stripe >> btrfs: scrub: introduce a helper to verify one metadata >> btrfs: scrub: introduce a helper to verify one scrub_stripe >> btrfs: scrub: introduce the main read repair worker for scrub_stripe >> btrfs: scrub: introduce a writeback helper for scrub_stripe >> btrfs: scrub: introduce error reporting functionality for scrub_stripe >> btrfs: scrub: introduce the helper to queue a stripe for scrub >> btrfs: scrub: switch scrub_simple_mirror() to scrub_stripe >> infrastructure > > The whole series follows the pattern to first introduce the individual > helpers that can be reviewed separately and then does the switch in one > patch. As the whole scrub IO path is reworked I don't think we can do > much better so clearly separating the old and new logic sounds OK. > > One comment I have, the functional switch in the last patch should not > be mixed with deleting of the unused code. As the last patch activates > code from all the previous patches it would also show up in any > bisection as the cause so it would help to narrow the focus only on the > real changes. > > There are some minor coding style issues I'll point out under the > patches. I'm assuming that the scrub structure won't change again soon > (the old code is from 3.x times) so let's use this opportunity to make > the style most up to date.
On Thu, Mar 23, 2023 at 02:28:16PM +0800, Qu Wenruo wrote: > > > On 2023/3/21 08:09, David Sterba wrote: > > On Mon, Mar 20, 2023 at 10:12:46AM +0800, Qu Wenruo wrote: > >> [TODO] > >> > >> - More testing on zoned devices > >> Now the patchset can already pass all scrub/replace groups with > >> regular devices. > > > > I think I noticed some disparity in the old and new code for the zoned > > devices. This should be found by testing so I'd add this series to > > for-next and see. > > Just want to be sure, if I want to further update the series (mostly > style and small cleanups), I should just base all my updates on your > for-next branch, right? No, please base it on misc-next. For-next is for an early testing but patchsets can be updated or completely dropped.
On 2023/3/24 01:51, David Sterba wrote: > On Thu, Mar 23, 2023 at 02:28:16PM +0800, Qu Wenruo wrote: >> >> >> On 2023/3/21 08:09, David Sterba wrote: >>> On Mon, Mar 20, 2023 at 10:12:46AM +0800, Qu Wenruo wrote: >>>> [TODO] >>>> >>>> - More testing on zoned devices >>>> Now the patchset can already pass all scrub/replace groups with >>>> regular devices. >>> >>> I think I noticed some disparity in the old and new code for the zoned >>> devices. This should be found by testing so I'd add this series to >>> for-next and see. >> >> Just want to be sure, if I want to further update the series (mostly >> style and small cleanups), I should just base all my updates on your >> for-next branch, right? > > No, please base it on misc-next. For-next is for an early testing but > patchsets can be updated or completely dropped. My bad, my question should be: Should I fetch all the patches from for-next? Because I thought there may be some modification when you apply the patches, but it turns out it's really applied as is, so no need for that. All my patches are and will always be based on misc-next. (Although sometimes it's some older misc-next) Thanks, Qu
On Fri, Mar 24, 2023 at 08:42:22AM +0800, Qu Wenruo wrote: > > > On 2023/3/24 01:51, David Sterba wrote: > > On Thu, Mar 23, 2023 at 02:28:16PM +0800, Qu Wenruo wrote: > >> > >> > >> On 2023/3/21 08:09, David Sterba wrote: > >>> On Mon, Mar 20, 2023 at 10:12:46AM +0800, Qu Wenruo wrote: > >>>> [TODO] > >>>> > >>>> - More testing on zoned devices > >>>> Now the patchset can already pass all scrub/replace groups with > >>>> regular devices. > >>> > >>> I think I noticed some disparity in the old and new code for the zoned > >>> devices. This should be found by testing so I'd add this series to > >>> for-next and see. > >> > >> Just want to be sure, if I want to further update the series (mostly > >> style and small cleanups), I should just base all my updates on your > >> for-next branch, right? > > > > No, please base it on misc-next. For-next is for an early testing but > > patchsets can be updated or completely dropped. > > My bad, my question should be: Should I fetch all the patches from for-next? > > Because I thought there may be some modification when you apply the > patches, but it turns out it's really applied as is, so no need for that. Ah I see what you mean, yeah that's a valid question. For patches that get feedback regarding non-trivial changes I don't do my edits until it's more or less finalized. This is implied by the status in the mailing list, not reflected in the branch names, or if there's a tracking issue for the patchset I add the 'update' label.