lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 05 Sep 2011 17:05:57 +0200
From:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
To:	Wu Fengguang <fengguang.wu@...el.com>
Cc:	linux-fsdevel@...r.kernel.org, Jan Kara <jack@...e.cz>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Christoph Hellwig <hch@....de>,
	Dave Chinner <david@...morbit.com>,
	Greg Thelen <gthelen@...gle.com>,
	Minchan Kim <minchan.kim@...il.com>,
	Vivek Goyal <vgoyal@...hat.com>,
	Andrea Righi <arighi@...eler.com>,
	linux-mm <linux-mm@...ck.org>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 02/18] writeback: dirty position control

On Sun, 2011-09-04 at 09:53 +0800, Wu Fengguang wrote:
> @@ -591,6 +790,7 @@ static void global_update_bandwidth(unsi
>  
>  void __bdi_update_bandwidth(struct backing_dev_info *bdi,
>                             unsigned long thresh,
> +                           unsigned long bg_thresh,
>                             unsigned long dirty,
>                             unsigned long bdi_thresh,
>                             unsigned long bdi_dirty,
> @@ -627,6 +827,7 @@ snapshot:
>  
>  static void bdi_update_bandwidth(struct backing_dev_info *bdi,
>                                  unsigned long thresh,
> +                                unsigned long bg_thresh,
>                                  unsigned long dirty,
>                                  unsigned long bdi_thresh,
>                                  unsigned long bdi_dirty,
> @@ -635,8 +836,8 @@ static void bdi_update_bandwidth(struct 
>         if (time_is_after_eq_jiffies(bdi->bw_time_stamp + BANDWIDTH_INTERVAL))
>                 return;
>         spin_lock(&bdi->wb.list_lock);
> -       __bdi_update_bandwidth(bdi, thresh, dirty, bdi_thresh, bdi_dirty,
> -                              start_time);
> +       __bdi_update_bandwidth(bdi, thresh, bg_thresh, dirty,
> +                              bdi_thresh, bdi_dirty, start_time);
>         spin_unlock(&bdi->wb.list_lock);
>  }
>  
> @@ -677,7 +878,8 @@ static void balance_dirty_pages(struct a
>                  * catch-up. This avoids (excessively) small writeouts
>                  * when the bdi limits are ramping up.
>                  */
> -               if (nr_dirty <= (background_thresh + dirty_thresh) / 2)
> +               if (nr_dirty <= dirty_freerun_ceiling(dirty_thresh,
> +                                                     background_thresh))
>                         break;
>  
>                 bdi_thresh = bdi_dirty_limit(bdi, dirty_thresh);
> @@ -721,8 +923,9 @@ static void balance_dirty_pages(struct a
>                 if (!bdi->dirty_exceeded)
>                         bdi->dirty_exceeded = 1;
>  
> -               bdi_update_bandwidth(bdi, dirty_thresh, nr_dirty,
> -                                    bdi_thresh, bdi_dirty, start_time);
> +               bdi_update_bandwidth(bdi, dirty_thresh, background_thresh,
> +                                    nr_dirty, bdi_thresh, bdi_dirty,
> +                                    start_time);
>  
>                 /* Note: nr_reclaimable denotes nr_dirty + nr_unstable.
>                  * Unstable writes are a feature of certain networked
> --- linux-next.orig/fs/fs-writeback.c   2011-08-26 15:57:18.000000000 +0800
> +++ linux-next/fs/fs-writeback.c        2011-08-26 15:57:20.000000000 +0800
> @@ -675,7 +675,7 @@ static inline bool over_bground_thresh(v
>  static void wb_update_bandwidth(struct bdi_writeback *wb,
>                                 unsigned long start_time)
>  {
> -       __bdi_update_bandwidth(wb->bdi, 0, 0, 0, 0, start_time);
> +       __bdi_update_bandwidth(wb->bdi, 0, 0, 0, 0, 0, start_time);
>  }
>  
>  /*
> --- linux-next.orig/include/linux/writeback.h   2011-08-26 15:57:18.000000000 +0800
> +++ linux-next/include/linux/writeback.h        2011-08-26 15:57:20.000000000 +0800
> @@ -141,6 +141,7 @@ unsigned long bdi_dirty_limit(struct bac
>  
>  void __bdi_update_bandwidth(struct backing_dev_info *bdi,
>                             unsigned long thresh,
> +                           unsigned long bg_thresh,
>                             unsigned long dirty,
>                             unsigned long bdi_thresh,
>                             unsigned long bdi_dirty,


All this function signature muck doesn't seem immediately relevant to
the introduction of bdi_position_ratio() since the new function isn't
actually used.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ