int size, pgprot_t page_prot)
{
agp_segment_priv *seg;
- int num_segments, pg_start, pg_count, i;
+ int num_segments, i;
+ off_t pg_start;
+ size_t pg_count;
pg_start = offset / 4096;
pg_count = size / 4096;
agp_segment_priv **ret_seg;
agp_segment_priv *seg;
agp_segment *user_seg;
- int i;
+ size_t i;
seg = kmalloc((sizeof(agp_segment_priv) * region->seg_count), GFP_KERNEL);
if (seg == NULL) {
static int agp_mmap(struct file *file, struct vm_area_struct *vma)
{
- int size;
- int current_size;
+ unsigned int size, current_size;
unsigned long offset;
agp_client *client;
agp_file_private *priv = (agp_file_private *) file->private_data;
void agp_free_memory(agp_memory * curr)
{
- int i;
+ size_t i;
if ((agp_bridge.type == NOT_SUPPORTED) || (curr == NULL))
return;
{
int scratch_pages;
agp_memory *new;
- int i;
+ size_t i;
if (agp_bridge.type == NOT_SUPPORTED)
return NULL;
int agp_generic_insert_memory(agp_memory * mem, off_t pg_start, int type)
{
- int i, j, num_entries;
+ int num_entries;
+ size_t i;
+ off_t j;
void *temp;
temp = agp_bridge.current_size;
int agp_generic_remove_memory(agp_memory * mem, off_t pg_start, int type)
{
- int i;
+ size_t i;
if (type != 0 || mem->type != 0) {
/* The generic routines know nothing of memory types */