Accessing GPIO

I'm having trouble accessing the GPIO ports on my OMAP. I'm actually
using the Mistral OMAP3evm, not the Beagle, but I figured they be
similar enough to ask here. I'm trying to access the SYSCONFIG
register of GPIO5, which should be address 0x49056010. I'm trying to
use the mmap function to map that address to a variable for read write
purposes. When I try to read from the array I get an error:
" Unhandled fault: external abort on non-linefetch (0x1018) at

Bus error"

I read in a previous post that this has to do with not have clocks
enabled, however there is no mention of how to enable them. Can I do
this within my program or do I need to modify the kernel / bootloader?
Also does anyone know of any libraries that contain functions for
reading and writing to the GPIO ports?

I'm including my code for reference:

/* Include files */
#include <stdio.h>
#include <sys/mman.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sys/stat.h>

#define SYSCONFIG 0x49056010

int main(void)
  int fd;
  unsigned int *regs;
  unsigned int value;
  char junk;
  fd = open("/dev/mem", O_RDWR);
  regs = mmap(SYSCONFIG,4,PROT_READ,MAP_SHARED,fd,0);
  value = regs[0];
  printf("Value is: 0x%x\n",value);