target/linux/bmips/files/drivers/pci/controller/pcie-bcm6328.c
static int postprocess_read(u32 data, int where, unsigned int size)
{
	u32 ret = 0;

	switch (size) {
	case 1:
		ret = (data >> ((where & 3) << 3)) & 0xff;
		break;
	case 2:
		ret = (data >> ((where & 3) << 3)) & 0xffff;
		break;
	case 4:
		ret = data;
		break;
	}

	return ret;
}
/*
 * swizzle 32bits data to return only the needed part
 */
swizzle 32bits data to return only the needed part
swizzle 32bits data to return only the needed part
static int postprocess_read(u32 data, int where, unsigned int size)
{
	u32 ret = 0;
	switch (size) {
	case 1:
		ret = (data >> ((where & 3) << 3)) & 0xff;
		break;
	case 2:
		ret = (data >> ((where & 3) << 3)) & 0xffff;
		break;
	case 4:
		ret = data;
		break;
	}
	return ret;
}
static int postprocess_read ( u32 data , int where , unsigned int size ) { u32 ret = 0 ; switch ( size ) { case 1 : ret = ( data >> ( ( where & 3 ) << 3 ) ) & 0xff ; break ; case 2 : ret = ( data >> ( ( where & 3 ) << 3 ) ) & 0xffff ; break ; case 4 : ret = data ; break ; } return ret ; }
swizzle 32bits data to return only the needed part
swizzle 32bits data to return only the needed part