title: pad configuration by mmap
body: <p>I have a beagleboard-xm rev C board. the TRM of the processor. I see some examples how to do pad configuration on the Net. here is one of the examples:</p>
  
  <pre><code> int fd = open("/dev/mem", O_RDWR | O_SYNC);
  if (fd &lt; 0) {
    printf("Could not open memory\n");
    exit(1);
  }
  
  // Pad configuration
  volatile ulong *pinconf;
  pinconf = (ulong*) mmap(NULL, 0x10000, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0x48000000);
  if (pinconf == MAP_FAILED) {
    printf("Pinconf Mapping failed\n");
    close(fd);
    exit(1);
  }
  // configure expansion header
  pinconf[0x2174/4] = 0x001A001A; //
  close(fd);
  </code></pre>
  
  <p>My question is that what is the purpose of dividing <code>0x2174</code> by 4? </p>
  
  <p>I see that 0x2174 represents the pin I would like to configure(<code>CONTROL_PADCONF_UART2_CTS[15:0]</code>) on <a href="http://www.ti.com/lit/ug/spruf98x/spruf98x.pdf" rel="nofollow">http://www.ti.com/lit/ug/spruf98x/spruf98x.pdf</a> page778. I see that it is a 32 bit register. But I cannot get the functionality 0x2174 by 4 points the lower 16 bit of that register?</p>