linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: manual merge of the akpm-current tree with the staging tree
@ 2012-10-29  3:21 Stephen Rothwell
  0 siblings, 0 replies; 4+ messages in thread
From: Stephen Rothwell @ 2012-10-29  3:21 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-next, linux-kernel, Greg KH, Andy Shevchenko

[-- Attachment #1: Type: text/plain, Size: 460 bytes --]

Hi Andrew,

Today's linux-next merge of the akpm-current tree got a conflict in
drivers/staging/rts_pstor/trace.h between commit cd2112220b6b ("Staging:
remove rts_pstor driver") from the staging tree and commit 3980a6d4af3e
("staging: rts_pstor: use kbasename()") from the akpm-current tree.

The former removed the file modified by the latter, so I dropped the
latter patch.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* linux-next: manual merge of the akpm-current tree with the staging tree
@ 2013-10-28 13:27 Stephen Rothwell
  0 siblings, 0 replies; 4+ messages in thread
From: Stephen Rothwell @ 2013-10-28 13:27 UTC (permalink / raw)
  To: Andrew Morton
  Cc: linux-next, linux-kernel, Srinivas Pandruvada, Jonathan Cameron,
	Greg KH, Alexander Holler

[-- Attachment #1: Type: text/plain, Size: 1949 bytes --]

Hi Andrew,

Today's linux-next merge of the akpm-current tree got a conflict in
drivers/rtc/rtc-hid-sensor-time.c between commit 476b9547e872 ("HID RTC:
Open sensor hub open close") from the staging tree and commit
356c3c0a98b8 ("drivers/rtc/rtc-hid-sensor-time.c: enable HID input
processing early") from the akpm-current tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

diff --cc drivers/rtc/rtc-hid-sensor-time.c
index 45560ffb038d,22254f08cea2..000000000000
--- a/drivers/rtc/rtc-hid-sensor-time.c
+++ b/drivers/rtc/rtc-hid-sensor-time.c
@@@ -275,21 -275,22 +275,28 @@@ static int hid_time_probe(struct platfo
  		return ret;
  	}
  
 +	ret = sensor_hub_device_open(hsdev);
 +	if (ret) {
 +		dev_err(&pdev->dev, "failed to open sensor hub device!\n");
 +		goto err_open;
 +	}
 +
+ 	/*
+ 	 * Enable HID input processing early in order to be able to read the
+ 	 * clock already in devm_rtc_device_register().
+ 	 */
+ 	hid_device_io_start(hsdev->hdev);
+ 
  	time_state->rtc = devm_rtc_device_register(&pdev->dev,
  					"hid-sensor-time", &hid_time_rtc_ops,
  					THIS_MODULE);
  
  	if (IS_ERR_OR_NULL(time_state->rtc)) {
+ 		hid_device_io_stop(hsdev->hdev);
  		ret = time_state->rtc ? PTR_ERR(time_state->rtc) : -ENODEV;
  		time_state->rtc = NULL;
 -		sensor_hub_remove_callback(hsdev, HID_USAGE_SENSOR_TIME);
  		dev_err(&pdev->dev, "rtc device register failed!\n");
 +		goto err_rtc;
  	}
  
  	return ret;
@@@ -303,9 -298,8 +310,9 @@@ err_open
  
  static int hid_time_remove(struct platform_device *pdev)
  {
- 	struct hid_sensor_hub_device *hsdev = pdev->dev.platform_data;
+ 	struct hid_sensor_hub_device *hsdev = dev_get_platdata(&pdev->dev);
  
 +	sensor_hub_device_close(hsdev);
  	sensor_hub_remove_callback(hsdev, HID_USAGE_SENSOR_TIME);
  
  	return 0;

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: linux-next: manual merge of the akpm-current tree with the staging tree
  2013-07-24  5:57 Stephen Rothwell
@ 2013-07-24  7:00 ` Peng Tao
  0 siblings, 0 replies; 4+ messages in thread
From: Peng Tao @ 2013-07-24  7:00 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Andrew Morton, linux-next, Linux Kernel Mailing List,
	Oleg Drokin, Greg KH

On Wed, Jul 24, 2013 at 1:57 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi Andrew,
>
> Today's linux-next merge of the akpm-current tree got a conflict in
> drivers/staging/lustre/lustre/ldlm/ldlm_pool.c between commit
> 91a50030f05e ("staging/lustre/ldlm: split client namespaces into active
> and inactive") from the staging tree and commit 48a91248649f
> ("staging/lustre/ldlm: convert to shrinkers to count/scan API") from the
> akpm-current tree.
>
> I fixed it up (I think - see below) and can carry the fix as necessary
> (no action is required).
>
Hi Stephen,

How will such conflicts be handled in the end? Do I need to send
rebased patch to Andrew?

Thanks,
Tao

> --
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au
>
> diff --cc drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
> index 101af4b,4c41e02..0000000
> --- a/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
> +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
> @@@ -597,16 -594,17 +593,17 @@@ int ldlm_pool_recalc(struct ldlm_pool *
>                 count = pl->pl_ops->po_recalc(pl);
>                 lprocfs_counter_add(pl->pl_stats, LDLM_POOL_RECALC_STAT,
>                                     count);
>  -              return count;
>         }
>  +      recalc_interval_sec = pl->pl_recalc_time - cfs_time_current_sec() +
>  +                            pl->pl_recalc_period;
>
>  -      return 0;
>  +      return recalc_interval_sec;
>   }
>  -EXPORT_SYMBOL(ldlm_pool_recalc);
>
> - /**
> + /*
>    * Pool shrink wrapper. Will call either client or server pool recalc callback
> -  * depending what pool \a pl is used.
> +  * depending what pool pl is used. When nr == 0, just return the number of
> +  * freeable locks. Otherwise, return the number of canceled locks.
>    */
>   int ldlm_pool_shrink(struct ldlm_pool *pl, int nr,
>                      unsigned int gfp_mask)
> @@@ -1028,26 -1025,20 +1025,21 @@@ static struct ptlrpc_thread *ldlm_pools
>   static struct completion ldlm_pools_comp;
>
>   /*
> -  * Cancel \a nr locks from all namespaces (if possible). Returns number of
> -  * cached locks after shrink is finished. All namespaces are asked to
> -  * cancel approximately equal amount of locks to keep balancing.
> +  * count locks from all namespaces (if possible). Returns number of
> +  * cached locks.
>    */
> - static int ldlm_pools_shrink(ldlm_side_t client, int nr,
> -                            unsigned int gfp_mask)
> + static unsigned long ldlm_pools_count(ldlm_side_t client, unsigned int gfp_mask)
>   {
> -       int total = 0, cached = 0, nr_ns;
> +       unsigned long total = 0, nr_ns;
>         struct ldlm_namespace *ns;
>  +      struct ldlm_namespace *ns_old = NULL; /* loop detection */
>         void *cookie;
>
> -       if (client == LDLM_NAMESPACE_CLIENT && nr != 0 &&
> -           !(gfp_mask & __GFP_FS))
> -               return -1;
> +       if (client == LDLM_NAMESPACE_CLIENT && !(gfp_mask & __GFP_FS))
> +               return 0;
>
> -       CDEBUG(D_DLMTRACE, "Request to shrink %d %s locks from all pools\n",
> -              nr, client == LDLM_NAMESPACE_CLIENT ? "client" : "server");
> +       CDEBUG(D_DLMTRACE, "Request to count %s locks from all pools\n",
> +              client == LDLM_NAMESPACE_CLIENT ? "client" : "server");
>
>         cookie = cl_env_reenter();
>
> @@@ -1094,8 -1080,8 +1096,8 @@@ static unsigned long ldlm_pools_scan(ld
>         /*
>          * Shrink at least ldlm_namespace_nr(client) namespaces.
>          */
> -       for (nr_ns = ldlm_namespace_nr_read(client) - nr_ns;
> -            nr_ns > 0; nr_ns--)
>  -      for (tmp = nr_ns = atomic_read(ldlm_namespace_nr(client));
> ++      for (tmp = nr_ns = ldlm_namespace_nr_read(client) - nr_ns;
> +            tmp > 0; tmp--)
>         {
>                 int cancel, nr_locks;
>
> @@@ -1125,26 -1108,36 +1124,36 @@@
>                 ldlm_namespace_put(ns);
>         }
>         cl_env_reexit(cookie);
> -       /* we only decrease the SLV in server pools shrinker, return -1 to
> -        * kernel to avoid needless loop. LU-1128 */
> -       return (client == LDLM_NAMESPACE_SERVER) ? -1 : cached;
> +       /*
> +        * we only decrease the SLV in server pools shrinker, return
> +        * SHRINK_STOP to kernel to avoid needless loop. LU-1128
> +        */
> +       return (client == LDLM_NAMESPACE_SERVER) ? SHRINK_STOP : freed;
> + }
> +
> + static unsigned long ldlm_pools_srv_count(struct shrinker *s, struct shrink_control *sc)
> + {
> +       return ldlm_pools_count(LDLM_NAMESPACE_SERVER, sc->gfp_mask);
>   }
>
> - static int ldlm_pools_srv_shrink(SHRINKER_ARGS(sc, nr_to_scan, gfp_mask))
> + static unsigned long ldlm_pools_srv_scan(struct shrinker *s, struct shrink_control *sc)
>   {
> -       return ldlm_pools_shrink(LDLM_NAMESPACE_SERVER,
> -                                shrink_param(sc, nr_to_scan),
> -                                shrink_param(sc, gfp_mask));
> +       return ldlm_pools_scan(LDLM_NAMESPACE_SERVER, sc->nr_to_scan,
> +                              sc->gfp_mask);
>   }
>
> - static int ldlm_pools_cli_shrink(SHRINKER_ARGS(sc, nr_to_scan, gfp_mask))
> + static unsigned long ldlm_pools_cli_count(struct shrinker *s, struct shrink_control *sc)
>   {
> -       return ldlm_pools_shrink(LDLM_NAMESPACE_CLIENT,
> -                                shrink_param(sc, nr_to_scan),
> -                                shrink_param(sc, gfp_mask));
> +       return ldlm_pools_count(LDLM_NAMESPACE_CLIENT, sc->gfp_mask);
> + }
> +
> + static unsigned long ldlm_pools_cli_scan(struct shrinker *s, struct shrink_control *sc)
> + {
> +       return ldlm_pools_scan(LDLM_NAMESPACE_CLIENT, sc->nr_to_scan,
> +                              sc->gfp_mask);
>   }
>
>  -void ldlm_pools_recalc(ldlm_side_t client)
>  +int ldlm_pools_recalc(ldlm_side_t client)
>   {
>         __u32 nr_l = 0, nr_p = 0, l;
>         struct ldlm_namespace *ns;

^ permalink raw reply	[flat|nested] 4+ messages in thread

* linux-next: manual merge of the akpm-current tree with the staging tree
@ 2013-07-24  5:57 Stephen Rothwell
  2013-07-24  7:00 ` Peng Tao
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Rothwell @ 2013-07-24  5:57 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-next, linux-kernel, Peng Tao, Oleg Drokin, Greg KH

[-- Attachment #1: Type: text/plain, Size: 5104 bytes --]

Hi Andrew,

Today's linux-next merge of the akpm-current tree got a conflict in
drivers/staging/lustre/lustre/ldlm/ldlm_pool.c between commit
91a50030f05e ("staging/lustre/ldlm: split client namespaces into active
and inactive") from the staging tree and commit 48a91248649f
("staging/lustre/ldlm: convert to shrinkers to count/scan API") from the
akpm-current tree.

I fixed it up (I think - see below) and can carry the fix as necessary
(no action is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

diff --cc drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
index 101af4b,4c41e02..0000000
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c
@@@ -597,16 -594,17 +593,17 @@@ int ldlm_pool_recalc(struct ldlm_pool *
  		count = pl->pl_ops->po_recalc(pl);
  		lprocfs_counter_add(pl->pl_stats, LDLM_POOL_RECALC_STAT,
  				    count);
 -		return count;
  	}
 +	recalc_interval_sec = pl->pl_recalc_time - cfs_time_current_sec() +
 +			      pl->pl_recalc_period;
  
 -	return 0;
 +	return recalc_interval_sec;
  }
 -EXPORT_SYMBOL(ldlm_pool_recalc);
  
- /**
+ /*
   * Pool shrink wrapper. Will call either client or server pool recalc callback
-  * depending what pool \a pl is used.
+  * depending what pool pl is used. When nr == 0, just return the number of
+  * freeable locks. Otherwise, return the number of canceled locks.
   */
  int ldlm_pool_shrink(struct ldlm_pool *pl, int nr,
  		     unsigned int gfp_mask)
@@@ -1028,26 -1025,20 +1025,21 @@@ static struct ptlrpc_thread *ldlm_pools
  static struct completion ldlm_pools_comp;
  
  /*
-  * Cancel \a nr locks from all namespaces (if possible). Returns number of
-  * cached locks after shrink is finished. All namespaces are asked to
-  * cancel approximately equal amount of locks to keep balancing.
+  * count locks from all namespaces (if possible). Returns number of
+  * cached locks.
   */
- static int ldlm_pools_shrink(ldlm_side_t client, int nr,
- 			     unsigned int gfp_mask)
+ static unsigned long ldlm_pools_count(ldlm_side_t client, unsigned int gfp_mask)
  {
- 	int total = 0, cached = 0, nr_ns;
+ 	unsigned long total = 0, nr_ns;
  	struct ldlm_namespace *ns;
 +	struct ldlm_namespace *ns_old = NULL; /* loop detection */
  	void *cookie;
  
- 	if (client == LDLM_NAMESPACE_CLIENT && nr != 0 &&
- 	    !(gfp_mask & __GFP_FS))
- 		return -1;
+ 	if (client == LDLM_NAMESPACE_CLIENT && !(gfp_mask & __GFP_FS))
+ 		return 0;
  
- 	CDEBUG(D_DLMTRACE, "Request to shrink %d %s locks from all pools\n",
- 	       nr, client == LDLM_NAMESPACE_CLIENT ? "client" : "server");
+ 	CDEBUG(D_DLMTRACE, "Request to count %s locks from all pools\n",
+ 	       client == LDLM_NAMESPACE_CLIENT ? "client" : "server");
  
  	cookie = cl_env_reenter();
  
@@@ -1094,8 -1080,8 +1096,8 @@@ static unsigned long ldlm_pools_scan(ld
  	/*
  	 * Shrink at least ldlm_namespace_nr(client) namespaces.
  	 */
- 	for (nr_ns = ldlm_namespace_nr_read(client) - nr_ns;
- 	     nr_ns > 0; nr_ns--)
 -	for (tmp = nr_ns = atomic_read(ldlm_namespace_nr(client));
++	for (tmp = nr_ns = ldlm_namespace_nr_read(client) - nr_ns;
+ 	     tmp > 0; tmp--)
  	{
  		int cancel, nr_locks;
  
@@@ -1125,26 -1108,36 +1124,36 @@@
  		ldlm_namespace_put(ns);
  	}
  	cl_env_reexit(cookie);
- 	/* we only decrease the SLV in server pools shrinker, return -1 to
- 	 * kernel to avoid needless loop. LU-1128 */
- 	return (client == LDLM_NAMESPACE_SERVER) ? -1 : cached;
+ 	/*
+ 	 * we only decrease the SLV in server pools shrinker, return
+ 	 * SHRINK_STOP to kernel to avoid needless loop. LU-1128
+ 	 */
+ 	return (client == LDLM_NAMESPACE_SERVER) ? SHRINK_STOP : freed;
+ }
+ 
+ static unsigned long ldlm_pools_srv_count(struct shrinker *s, struct shrink_control *sc)
+ {
+ 	return ldlm_pools_count(LDLM_NAMESPACE_SERVER, sc->gfp_mask);
  }
  
- static int ldlm_pools_srv_shrink(SHRINKER_ARGS(sc, nr_to_scan, gfp_mask))
+ static unsigned long ldlm_pools_srv_scan(struct shrinker *s, struct shrink_control *sc)
  {
- 	return ldlm_pools_shrink(LDLM_NAMESPACE_SERVER,
- 				 shrink_param(sc, nr_to_scan),
- 				 shrink_param(sc, gfp_mask));
+ 	return ldlm_pools_scan(LDLM_NAMESPACE_SERVER, sc->nr_to_scan,
+ 			       sc->gfp_mask);
  }
  
- static int ldlm_pools_cli_shrink(SHRINKER_ARGS(sc, nr_to_scan, gfp_mask))
+ static unsigned long ldlm_pools_cli_count(struct shrinker *s, struct shrink_control *sc)
  {
- 	return ldlm_pools_shrink(LDLM_NAMESPACE_CLIENT,
- 				 shrink_param(sc, nr_to_scan),
- 				 shrink_param(sc, gfp_mask));
+ 	return ldlm_pools_count(LDLM_NAMESPACE_CLIENT, sc->gfp_mask);
+ }
+ 
+ static unsigned long ldlm_pools_cli_scan(struct shrinker *s, struct shrink_control *sc)
+ {
+ 	return ldlm_pools_scan(LDLM_NAMESPACE_CLIENT, sc->nr_to_scan,
+ 			       sc->gfp_mask);
  }
  
 -void ldlm_pools_recalc(ldlm_side_t client)
 +int ldlm_pools_recalc(ldlm_side_t client)
  {
  	__u32 nr_l = 0, nr_p = 0, l;
  	struct ldlm_namespace *ns;

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-10-28 13:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-29  3:21 linux-next: manual merge of the akpm-current tree with the staging tree Stephen Rothwell
2013-07-24  5:57 Stephen Rothwell
2013-07-24  7:00 ` Peng Tao
2013-10-28 13:27 Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).