/* Get value of operand 2 (in a LDR instruction)  */
static unsigned long ptrace_getldrop2(struct task_struct *child, unsigned long insn)
/* Get value of operand 2 (in a LDR instruction)  */
static unsigned long ptrace_getldrop2(struct task_struct *child, unsigned long insn)
{
	unsigned long val;
	int shift;
	int type;
	val = get_user_reg(child, insn & 15);
	shift = (insn >> 7) & 31;
	type = (insn >> 5) & 3;
	switch (type) {
	case 0:	val <<= shift;	break;
	case 1:	val >>= shift;	break;
	case 2:
		val = (((signed long)val) >> shift);
		break;
	case 3:
 		val = (val >> shift) | (val << (32 - shift));
		break;
	}
	return val;
}