Hello, I'm working on an exercise involving pointer arithmetic and 2D arrays. I can't use subscription and it must be done in a single loop. Here's the code that causing me heart ache:

Code:
#include <stdio.h>
// C Programming - a modern approach, 2nd edition by K.N. King


const int b[4][6]= {{1,2,3,4,5,6},
                {1,2,3,4,5,6},
                {1,2,3,4,5,6},
                {1,2,3,4,5,6}};


//very bottom page.268 a funct for 1 dimensional array works for 2 dimensional
int sum_two_dimensional_array(const int a[], int n);


int main(void){
    int total;
    int num =(sizeof(b)/sizeof(b[0]));
    total = sum_two_dimensional_array(b, num);  //p265
    printf("total = %d\n",total);
}


int sum_two_dimensional_array(const int a[], int n){ //p265 look for 'const'
    const int *p;
    int sum;
    p = a;
    for(p=0; p<a+n; p++){           // top of p264 and bottom of p.269
        printf("p=%d\n",*p);
        sum += *p;
    }
    printf("sum = %d\n",sum);
    return sum;
}

Here is the compiler log:
Code:
||=== Build file: "no target" in "no project" (compiler: unknown) ===|
C:\work\programming-c\KN-King-C-programming\chapt-12-ex17.c||In function 'main':|
C:\work\programming-c\KN-King-C-programming\chapt-12-ex17.c|15|warning: passing argument 1 of 'sum_two_dimensional_array' from incompatible pointer type [-Wincompatible-pointer-types]|
C:\work\programming-c\KN-King-C-programming\chapt-12-ex17.c|10|note: expected 'const int *' but argument is of type 'const int (*)[6]'|
||=== Build finished: 0 error(s), 1 warning(s) (0 minute(s), 0 second(s)) ===|
The compiler is telling me that in line 15 the parameter 'b' is from "incompatible pointer type". I'm miss understanding something from my book because this should work.


Thank you for any insight.