Lines Matching refs:buflen

621 static int ldm_relative(const u8 *buffer, int buflen, int base, int offset)  in ldm_relative()  argument
625 if (!buffer || offset < 0 || base > buflen) { in ldm_relative()
630 if (base > buflen) in ldm_relative()
631 ldm_error("base (%d) > buflen (%d)", base, buflen); in ldm_relative()
634 if (base + buffer[base] >= buflen) { in ldm_relative()
636 buffer[base], buflen); in ldm_relative()
692 static int ldm_get_vstr (const u8 *block, u8 *buffer, int buflen) in ldm_get_vstr() argument
699 if (length >= buflen) { in ldm_get_vstr()
700 ldm_error ("Truncating string %d -> %d.", length, buflen); in ldm_get_vstr()
701 length = buflen - 1; in ldm_get_vstr()
720 static bool ldm_parse_cmp3 (const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_cmp3() argument
727 r_objid = ldm_relative (buffer, buflen, 0x18, 0); in ldm_parse_cmp3()
728 r_name = ldm_relative (buffer, buflen, 0x18, r_objid); in ldm_parse_cmp3()
729 r_vstate = ldm_relative (buffer, buflen, 0x18, r_name); in ldm_parse_cmp3()
730 r_child = ldm_relative (buffer, buflen, 0x1D, r_vstate); in ldm_parse_cmp3()
731 r_parent = ldm_relative (buffer, buflen, 0x2D, r_child); in ldm_parse_cmp3()
734 r_stripe = ldm_relative (buffer, buflen, 0x2E, r_parent); in ldm_parse_cmp3()
735 r_cols = ldm_relative (buffer, buflen, 0x2E, r_stripe); in ldm_parse_cmp3()
770 static int ldm_parse_dgr3 (const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_dgr3() argument
777 r_objid = ldm_relative (buffer, buflen, 0x18, 0); in ldm_parse_dgr3()
778 r_name = ldm_relative (buffer, buflen, 0x18, r_objid); in ldm_parse_dgr3()
779 r_diskid = ldm_relative (buffer, buflen, 0x18, r_name); in ldm_parse_dgr3()
782 r_id1 = ldm_relative (buffer, buflen, 0x24, r_diskid); in ldm_parse_dgr3()
783 r_id2 = ldm_relative (buffer, buflen, 0x24, r_id1); in ldm_parse_dgr3()
811 static bool ldm_parse_dgr4 (const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_dgr4() argument
818 r_objid = ldm_relative (buffer, buflen, 0x18, 0); in ldm_parse_dgr4()
819 r_name = ldm_relative (buffer, buflen, 0x18, r_objid); in ldm_parse_dgr4()
822 r_id1 = ldm_relative (buffer, buflen, 0x44, r_name); in ldm_parse_dgr4()
823 r_id2 = ldm_relative (buffer, buflen, 0x44, r_id1); in ldm_parse_dgr4()
849 static bool ldm_parse_dsk3 (const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_dsk3() argument
856 r_objid = ldm_relative (buffer, buflen, 0x18, 0); in ldm_parse_dsk3()
857 r_name = ldm_relative (buffer, buflen, 0x18, r_objid); in ldm_parse_dsk3()
858 r_diskid = ldm_relative (buffer, buflen, 0x18, r_name); in ldm_parse_dsk3()
859 r_altname = ldm_relative (buffer, buflen, 0x18, r_diskid); in ldm_parse_dsk3()
888 static bool ldm_parse_dsk4 (const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_dsk4() argument
895 r_objid = ldm_relative (buffer, buflen, 0x18, 0); in ldm_parse_dsk4()
896 r_name = ldm_relative (buffer, buflen, 0x18, r_objid); in ldm_parse_dsk4()
921 static bool ldm_parse_prt3(const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_prt3() argument
927 r_objid = ldm_relative(buffer, buflen, 0x18, 0); in ldm_parse_prt3()
932 r_name = ldm_relative(buffer, buflen, 0x18, r_objid); in ldm_parse_prt3()
937 r_size = ldm_relative(buffer, buflen, 0x34, r_name); in ldm_parse_prt3()
942 r_parent = ldm_relative(buffer, buflen, 0x34, r_size); in ldm_parse_prt3()
947 r_diskid = ldm_relative(buffer, buflen, 0x34, r_parent); in ldm_parse_prt3()
953 r_index = ldm_relative(buffer, buflen, 0x34, r_diskid); in ldm_parse_prt3()
995 static bool ldm_parse_vol5(const u8 *buffer, int buflen, struct vblk *vb) in ldm_parse_vol5() argument
1002 r_objid = ldm_relative(buffer, buflen, 0x18, 0); in ldm_parse_vol5()
1007 r_name = ldm_relative(buffer, buflen, 0x18, r_objid); in ldm_parse_vol5()
1012 r_vtype = ldm_relative(buffer, buflen, 0x18, r_name); in ldm_parse_vol5()
1017 r_disable_drive_letter = ldm_relative(buffer, buflen, 0x18, r_vtype); in ldm_parse_vol5()
1023 r_child = ldm_relative(buffer, buflen, 0x2D, r_disable_drive_letter); in ldm_parse_vol5()
1028 r_size = ldm_relative(buffer, buflen, 0x3D, r_child); in ldm_parse_vol5()
1034 r_id1 = ldm_relative(buffer, buflen, 0x52, r_size); in ldm_parse_vol5()
1042 r_id2 = ldm_relative(buffer, buflen, 0x52, r_id1); in ldm_parse_vol5()
1050 r_size2 = ldm_relative(buffer, buflen, 0x52, r_id2); in ldm_parse_vol5()
1058 r_drive = ldm_relative(buffer, buflen, 0x52, r_size2); in ldm_parse_vol5()