Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1170221
| Path | csiph.com!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Joe Perches <joe@perches.com> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] staging: ft1000: convert pack pragma to __packed__ attribute |
| Date | Mon, 22 Jun 2015 23:50:01 +0200 |
| Message-ID | <pEhLj-7Da-7@gated-at.bofh.it> (permalink) |
| References | <pEfq9-4kd-5@gated-at.bofh.it> |
| X-Original-To | Giedrius Statkevičius <giedrius.statkevicius@gmail.com> |
| X-Session-Marker | 6A6F6540706572636865732E636F6D |
| X-Spam-Summary | 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::,RULES_HIT:41:152:355:379:541:599:973:981:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2559:2562:2693:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3870:3872:4250:4321:4605:5007:6119:6261:7688:7903:8829:8957:9121:10004:10400:10848:11026:11232:11657:11658:11914:12043:12517:12519:12663:12740:13069:13311:13357:13894:21080,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0 |
| X-He-Tag | water79_66b2e0d4d8e3e |
| X-Filterd-Recvd-Size | 2199 |
| Content-Type | text/plain; charset="UTF-8" |
| X-Mailer | Evolution 3.12.11-0ubuntu3 |
| MIME-Version | 1.0 |
| Content-Transfer-Encoding | 8bit |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 30 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | gregkh@linuxfoundation.org, marek.belisko@gmail.com, tapaswenipathak@gmail.com, mahfouz.saif.elyazal@gmail.com, tinajohnson.1234@gmail.com, gulsah.1004@gmail.com, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org |
| X-Original-Date | Mon, 22 Jun 2015 14:48:24 -0700 |
| X-Original-Message-ID | <1435009704.9808.32.camel@perches.com> |
| X-Original-References | <1435000364-14556-1-git-send-email-giedrius.statkevicius@gmail.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | aioe.org linux.kernel:1170221 |
Show key headers only | View raw
On Mon, 2015-06-22 at 22:12 +0300, Giedrius Statkevičius wrote:
> Convert a Microsoft compiler specific directive "#pragma pack(1)" to a
> GCC equivalent __attribute__ ((__packed__)). Also, by doing this we save
> ourselves from trouble if any other struct definitions are added after
> the #pragma because it will be applied to all of the definitions
> following it.
[]
> diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_download.c b/drivers/staging/ft1000/ft1000-usb/ft1000_download.c
[]
> @@ -95,7 +95,6 @@ struct dsp_file_hdr {
> long nDspImages; /* Number of DSP images in file. */
> };
>
> -#pragma pack(1)
> struct dsp_image_info {
> long coff_date; /* Date/time when DSP Coff image was built. */
> long begin_offset; /* Offset in file where image begins. */
> @@ -105,7 +104,7 @@ struct dsp_image_info {
> long version; /* Embedded version # of DSP code. */
> unsigned short checksum; /* DSP File checksum */
> unsigned short pad1;
> -};
> +} __attribute__ ((__packed__));
__packed
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
Re: [PATCH] staging: ft1000: convert pack pragma to __packed__ attribute Joe Perches <joe@perches.com> - 2015-06-22 23:50 +0200
csiph-web