All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Jagan Teki <jteki@openedev.com>
Cc: devel@driverdev.osuosl.org,
	Florian Schilhabel <florian.c.schilhabel@googlemail.com>,
	Larry Finger <Larry.Finger@lwfinger.net>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: Re: [PATCH v2] staging: rtl8712: Use ether_addr_copy() instead of memcpy()
Date: Mon, 18 May 2015 19:08:59 +0300	[thread overview]
Message-ID: <20150518160859.GM14154@mwanda> (raw)
In-Reply-To: <CAD6G_RSt9q4hdj4Zo6w1xXJOE0ER_yg874BL1t7cbj2q7HY45Q@mail.gmail.com>


#include <stdio.h>

struct foo {
	unsigned char one;
	unsigned char two;
	unsigned char three;
	unsigned char mac_addr[6];
	unsigned short channel_plan;
};

int main(void)
{
	struct foo *p = NULL;

	printf("%x\n", &p->mac_addr);

	return 0;
}

This program does not print an even number so the alignment is off.

regards,
dan carpenter

      reply	other threads:[~2015-05-18 16:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-18 14:17 [PATCH v2] staging: rtl8712: Use ether_addr_copy() instead of memcpy() Jagan Teki
2015-05-18 14:38 ` Dan Carpenter
2015-05-18 16:04   ` Jagan Teki
2015-05-18 16:08     ` Dan Carpenter [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150518160859.GM14154@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=devel@driverdev.osuosl.org \
    --cc=florian.c.schilhabel@googlemail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jteki@openedev.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.