/alps/pcitool

To get this branch, use:
bzr branch http://suren.me/webbzr/alps/pcitool

« back to all changes in this revision

Viewing changes to tools.c

  • Committer: Suren A. Chilingaryan
  • Date: 2011-02-13 14:33:26 UTC
  • Revision ID: csa@dside.dyndns.org-20110213143326-ud52k05tc0qj35ps
Print a bit more details

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
    return (dst);
30
30
31
31
 
 
32
void *memcpy64(void * dst, void const * src, size_t len) {
 
33
    uint64_t * plDst = (uint64_t *) dst;
 
34
    uint64_t const * plSrc = (uint64_t const *) src;
 
35
 
 
36
    while (len >= 8) {
 
37
        *plDst++ = *plSrc++;
 
38
        len -= 4;
 
39
    }
 
40
 
 
41
    char * pcDst = (char *) plDst;
 
42
    char const * pcSrc = (char const *) plSrc;
 
43
 
 
44
    while (len--) {
 
45
        *pcDst++ = *pcSrc++;
 
46
    }
 
47
 
 
48
    return (dst);
 
49
 
50
 
32
51
 
33
52
int get_page_mask() {
34
53
    int pagesize,pagemask,temp;