Changeset df15e5f in mainline
- Timestamp:
- 2012-02-12T20:09:36Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- bd8bfc5a
- Parents:
- 4f64a523
- Location:
- uspace/srv
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/ethip/ethip_nic.c
r4f64a523 rdf15e5f 198 198 } 199 199 200 #include <stdio.h> 200 201 static void ethip_nic_received(ethip_nic_t *nic, ipc_callid_t callid, 201 202 ipc_call_t *call) … … 212 213 return; 213 214 } 215 216 log_msg(LVL_DEBUG, "Ethernet PDU contents (%zu bytes)", 217 size); 218 size_t i; 219 for (i = 0; i < size; i++) 220 printf("%02x ", ((uint8_t *)data)[i]); 221 printf("\n"); 214 222 215 223 log_msg(LVL_DEBUG, "call ethip_received"); -
uspace/srv/ethip/pdu.c
r4f64a523 rdf15e5f 76 76 } 77 77 78 #include <stdio.h> 78 79 /** Decode Ethernet PDU. */ 79 80 int eth_pdu_decode(void *data, size_t size, eth_frame_t *frame) … … 102 103 frame->size); 103 104 105 log_msg(LVL_DEBUG, "Ethernet frame src=%llx dest=%llx etype=%x", 106 frame->src, frame->dest, frame->etype_len); 107 log_msg(LVL_DEBUG, "Ethernet frame payload (%zu bytes)", frame->size); 108 size_t i; 109 for (i = 0; i < frame->size; i++) { 110 printf("%02x ", ((uint8_t *)(frame->data))[i]); 111 } 112 printf("\n"); 113 104 114 return EOK; 105 115 } … … 113 123 val = addr->addr; 114 124 for (i = 0; i < MAC48_BYTES; i++) { 115 bbuf[i] = (val >> 8*(MAC48_BYTES - i - 1)) & 0xff;125 bbuf[i] = (val >> (8 * (MAC48_BYTES - i - 1))) & 0xff; 116 126 val = val >> 8; 117 127 } … … 126 136 val = 0; 127 137 for (i = 0; i < MAC48_BYTES; i++) 128 val |= ( (uint64_t)bdata[i]) << (MAC48_BYTES - i - 1);138 val |= (uint64_t)bdata[i] << (8 * (MAC48_BYTES - i - 1)); 129 139 130 140 addr->addr = val; -
uspace/srv/tcp/tcp.c
r4f64a523 rdf15e5f 208 208 printf(NAME ": TCP (Transmission Control Protocol) network module\n"); 209 209 210 rc = log_init(NAME, LVL_ ERROR);210 rc = log_init(NAME, LVL_DEBUG); 211 211 if (rc != EOK) { 212 212 printf(NAME ": Failed to initialize log.\n");
Note:
See TracChangeset
for help on using the changeset viewer.