diff options
| author | Wolfgang Denk <wd@denx.de> | 2007-08-06 01:11:08 +0200 |
|---|---|---|
| committer | Wolfgang Denk <wd@denx.de> | 2007-08-06 01:11:08 +0200 |
| commit | f2c2a937d8c4a44f63ff88bf82023e03a29497a2 (patch) | |
| tree | fa8f7c9fb65d10259e76c40c52cf8277947424d4 /net/sntp.c | |
| parent | b1b54e352028ed370c3aa95d6fdeb9d64c5d2f86 (diff) | |
| parent | 5728be389e65fd47f34b33c2596271eb4db751ae (diff) | |
| download | olio-uboot-2014.01-f2c2a937d8c4a44f63ff88bf82023e03a29497a2.tar.xz olio-uboot-2014.01-f2c2a937d8c4a44f63ff88bf82023e03a29497a2.zip | |
Merge with /home/wd/git/u-boot/custodian/u-boot-testing
Diffstat (limited to 'net/sntp.c')
| -rw-r--r-- | net/sntp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/sntp.c b/net/sntp.c index db8c2c279..95e75422c 100644 --- a/net/sntp.c +++ b/net/sntp.c @@ -12,7 +12,7 @@ #include "sntp.h" -#if ((CONFIG_COMMANDS & CFG_CMD_NET) && (CONFIG_COMMANDS & CFG_CMD_SNTP)) +#if defined(CONFIG_CMD_NET) && defined(CONFIG_CMD_SNTP) #define SNTP_TIMEOUT 10 @@ -67,7 +67,7 @@ SntpHandler (uchar *pkt, unsigned dest, unsigned src, unsigned len) memcpy (&seconds, &rpktp->transmit_timestamp, sizeof(ulong)); to_tm(ntohl(seconds) - 2208988800UL + NetTimeOffset, &tm); -#if (CONFIG_COMMANDS & CFG_CMD_DATE) +#if defined(CONFIG_CMD_DATE) rtc_set (&tm); #endif printf ("Date: %4d-%02d-%02d Time: %2d:%02d:%02d\n", @@ -89,4 +89,4 @@ SntpStart (void) SntpSend (); } -#endif /* CONFIG_COMMANDS & CFG_CMD_SNTP */ +#endif |