* [PATCH] baycom_epp.c: Fix compilation with gcc-4.1.0-20050522
@ 2005-05-27 14:08 Alexey Dobriyan
2005-05-27 15:53 ` Stephen Hemminger
0 siblings, 1 reply; 2+ messages in thread
From: Alexey Dobriyan @ 2005-05-27 14:08 UTC (permalink / raw)
To: netdev; +Cc: Thomas Sailer
drivers/net/hamradio/baycom_epp.c:432: error: jump into statement expression
...
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
--- linux-vanilla/drivers/net/hamradio/baycom_epp.c 2005-05-27 12:58:48.000000000 +0400
+++ linux-gcc4/drivers/net/hamradio/baycom_epp.c 2005-05-27 17:54:14.000000000 +0400
@@ -380,22 +380,18 @@ static inline void do_kiss_params(struct
*/
#define ENCODEITERA(j) \
-({ \
if (!(notbitstream & (0x1f0 << j))) \
goto stuff##j; \
- encodeend##j: ; \
-})
+ encodeend##j: ;
#define ENCODEITERB(j) \
-({ \
stuff##j: \
bitstream &= ~(0x100 << j); \
bitbuf = (bitbuf & (((2 << j) << numbit) - 1)) | \
((bitbuf & ~(((2 << j) << numbit) - 1)) << 1); \
numbit++; \
notbitstream = ~bitstream; \
- goto encodeend##j; \
-})
+ goto encodeend##j;
static void encode_hdlc(struct baycom_state *bc)
@@ -611,16 +607,13 @@ static void do_rxpacket(struct net_devic
}
#define DECODEITERA(j) \
-({ \
if (!(notbitstream & (0x0fc << j))) /* flag or abort */ \
goto flgabrt##j; \
if ((bitstream & (0x1f8 << j)) == (0xf8 << j)) /* stuffed bit */ \
goto stuff##j; \
- enditer##j: ; \
-})
+ enditer##j: ;
#define DECODEITERB(j) \
-({ \
flgabrt##j: \
if (!(notbitstream & (0x1fc << j))) { /* abort received */ \
state = 0; \
@@ -638,8 +631,7 @@ static void do_rxpacket(struct net_devic
stuff##j: \
numbits--; \
bitbuf = (bitbuf & ((~0xff) << j)) | ((bitbuf & ~((~0xff) << j)) << 1); \
- goto enditer##j; \
-})
+ goto enditer##j;
static int receive(struct net_device *dev, int cnt)
{
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] baycom_epp.c: Fix compilation with gcc-4.1.0-20050522
2005-05-27 14:08 [PATCH] baycom_epp.c: Fix compilation with gcc-4.1.0-20050522 Alexey Dobriyan
@ 2005-05-27 15:53 ` Stephen Hemminger
0 siblings, 0 replies; 2+ messages in thread
From: Stephen Hemminger @ 2005-05-27 15:53 UTC (permalink / raw)
To: Alexey Dobriyan; +Cc: netdev, Thomas Sailer
On Fri, 27 May 2005 18:08:31 +0400
Alexey Dobriyan <adobriyan@gmail.com> wrote:
> drivers/net/hamradio/baycom_epp.c:432: error: jump into statement expression
> ...
>
> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
>
> --- linux-vanilla/drivers/net/hamradio/baycom_epp.c 2005-05-27 12:58:48.000000000 +0400
> +++ linux-gcc4/drivers/net/hamradio/baycom_epp.c 2005-05-27 17:54:14.000000000 +0400
> @@ -380,22 +380,18 @@ static inline void do_kiss_params(struct
> */
>
> #define ENCODEITERA(j) \
> -({ \
> if (!(notbitstream & (0x1f0 << j))) \
> goto stuff##j; \
> - encodeend##j: ; \
> -})
> + encodeend##j: ;
Ick... Please just kill this kind of macro crap
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-05-27 15:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-05-27 14:08 [PATCH] baycom_epp.c: Fix compilation with gcc-4.1.0-20050522 Alexey Dobriyan
2005-05-27 15:53 ` Stephen Hemminger
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).