All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] regmap: Remove __attribute__ ((packed))
@ 2013-03-14 15:26 Dimitris Papastamos
  2013-03-15  1:36 ` Mark Brown
  0 siblings, 1 reply; 5+ messages in thread
From: Dimitris Papastamos @ 2013-03-14 15:26 UTC (permalink / raw)
  To: Mark Brown; +Cc: patches, linux-kernel

There is no point having this.  The space gains are trivial if there
are any at all.

Change-Id: Ib4b1320420f780dcf5b9a1e4b05f5805691c4d9f
Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
---
 drivers/base/regmap/regcache-rbtree.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/base/regmap/regcache-rbtree.c b/drivers/base/regmap/regcache-rbtree.c
index dd5ed6c..383fc00 100644
--- a/drivers/base/regmap/regcache-rbtree.c
+++ b/drivers/base/regmap/regcache-rbtree.c
@@ -31,7 +31,7 @@ struct regcache_rbtree_node {
 	void *block;
 	/* number of registers available in the block */
 	unsigned int blklen;
-} __attribute__ ((packed));
+};
 
 struct regcache_rbtree_ctx {
 	struct rb_root root;
-- 
1.8.1.5


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

* Re: [PATCH] regmap: Remove __attribute__ ((packed))
  2013-03-14 15:26 [PATCH] regmap: Remove __attribute__ ((packed)) Dimitris Papastamos
@ 2013-03-15  1:36 ` Mark Brown
  2013-03-15 11:16   ` Dimitris Papastamos
  0 siblings, 1 reply; 5+ messages in thread
From: Mark Brown @ 2013-03-15  1:36 UTC (permalink / raw)
  To: Dimitris Papastamos; +Cc: patches, linux-kernel

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

On Thu, Mar 14, 2013 at 03:26:19PM +0000, Dimitris Papastamos wrote:
> There is no point having this.  The space gains are trivial if there
> are any at all.

Applied, but numbers would have been nice and...

> Change-Id: Ib4b1320420f780dcf5b9a1e4b05f5805691c4d9f

...this shouldn't be in upstream submissions.

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

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

* Re: [PATCH] regmap: Remove __attribute__ ((packed))
  2013-03-15  1:36 ` Mark Brown
@ 2013-03-15 11:16   ` Dimitris Papastamos
  2013-03-15 16:53     ` Mark Brown
  0 siblings, 1 reply; 5+ messages in thread
From: Dimitris Papastamos @ 2013-03-15 11:16 UTC (permalink / raw)
  To: Mark Brown; +Cc: patches, linux-kernel

On Fri, Mar 15, 2013 at 01:36:40AM +0000, Mark Brown wrote:
> On Thu, Mar 14, 2013 at 03:26:19PM +0000, Dimitris Papastamos wrote:
> > There is no point having this.  The space gains are trivial if there
> > are any at all.
> 
> Applied, but numbers would have been nice and...
> 
> > Change-Id: Ib4b1320420f780dcf5b9a1e4b05f5805691c4d9f
> 
> ...this shouldn't be in upstream submissions.

Oops, sorry for the Change-Id.

On my system there was no benefit of using it, it just happens
that the struct is aligned properly and needs no padding.

Thanks,
Dimitris

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

* Re: [PATCH] regmap: Remove __attribute__ ((packed))
  2013-03-15 11:16   ` Dimitris Papastamos
@ 2013-03-15 16:53     ` Mark Brown
  2013-03-15 21:22       ` Dimitris Papastamos
  0 siblings, 1 reply; 5+ messages in thread
From: Mark Brown @ 2013-03-15 16:53 UTC (permalink / raw)
  To: Dimitris Papastamos; +Cc: patches, linux-kernel

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

On Fri, Mar 15, 2013 at 11:16:02AM +0000, Dimitris Papastamos wrote:

> On my system there was no benefit of using it, it just happens
> that the struct is aligned properly and needs no padding.

OK, so which system was that and is it not possible that other systems
will get something useful from this?

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

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

* Re: [PATCH] regmap: Remove __attribute__ ((packed))
  2013-03-15 16:53     ` Mark Brown
@ 2013-03-15 21:22       ` Dimitris Papastamos
  0 siblings, 0 replies; 5+ messages in thread
From: Dimitris Papastamos @ 2013-03-15 21:22 UTC (permalink / raw)
  To: Mark Brown; +Cc: patches, linux-kernel

On Fri, Mar 15, 2013 at 04:53:51PM +0000, Mark Brown wrote:
> On Fri, Mar 15, 2013 at 11:16:02AM +0000, Dimitris Papastamos wrote:
> 
> > On my system there was no benefit of using it, it just happens
> > that the struct is aligned properly and needs no padding.
> 
> OK, so which system was that and is it not possible that other systems
> will get something useful from this?

Well I guess it has to do with the gcc cross compiler version that
I've got and the actual data layout of the linking rbtree node.
The data seems to be aligned on a 4-byte boundary anyhow and
that should be ok for many systems.

Thanks,
Dimitris

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

end of thread, other threads:[~2013-03-15 21:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-14 15:26 [PATCH] regmap: Remove __attribute__ ((packed)) Dimitris Papastamos
2013-03-15  1:36 ` Mark Brown
2013-03-15 11:16   ` Dimitris Papastamos
2013-03-15 16:53     ` Mark Brown
2013-03-15 21:22       ` Dimitris Papastamos

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.