]> git.baikalelectronics.ru Git - kernel.git/commitdiff
Merge part of branch 'for-next.instantiate' into for-next
authorAndreas Gruenbacher <agruenba@redhat.com>
Fri, 5 Aug 2022 16:37:03 +0000 (18:37 +0200)
committerAndreas Gruenbacher <agruenba@redhat.com>
Fri, 5 Aug 2022 16:37:03 +0000 (18:37 +0200)
1  2 
fs/gfs2/glock.c
fs/gfs2/rgrp.c
fs/gfs2/rgrp.h

diff --cc fs/gfs2/glock.c
index e540d12900992938d3b7ad3d397a9937bc8b1977,e79f17d6d001f2bca6e43a9cb608e25432b37aaf..0b36a16659b625d5cbfb8b6c24151cc1f5314693
@@@ -524,26 -533,19 +533,20 @@@ done
   */
  
  static int do_promote(struct gfs2_glock *gl)
- __releases(&gl->gl_lockref.lock)
- __acquires(&gl->gl_lockref.lock)
  {
-       struct gfs2_holder *gh, *tmp, *first_gh;
+       struct gfs2_holder *gh, *current_gh;
        bool incompat_holders_demoted = false;
-       bool lock_released;
-       int ret;
  
- restart:
-       first_gh = find_first_strong_holder(gl);
-       list_for_each_entry_safe(gh, tmp, &gl->gl_holders, gh_list) {
-               lock_released = false;
+       current_gh = find_first_strong_holder(gl);
+       list_for_each_entry(gh, &gl->gl_holders, gh_list) {
                if (test_bit(HIF_HOLDER, &gh->gh_iflags))
                        continue;
-               if (!may_grant(gl, first_gh, gh)) {
+               if (!may_grant(gl, current_gh, gh)) {
                        /*
 -                       * If we get here, it means we may not grant this holder for
 -                       * some reason. If this holder is the head of the list, it
 -                       * means we have a blocked holder at the head, so return 1.
 +                       * If we get here, it means we may not grant this
 +                       * holder for some reason. If this holder is at the
 +                       * head of the list, it means we have a blocked holder
 +                       * at the head, so return 1.
                         */
                        if (list_is_first(&gh->gh_list, &gl->gl_holders))
                                return 1;
diff --cc fs/gfs2/rgrp.c
Simple merge
diff --cc fs/gfs2/rgrp.h
Simple merge