Searched refs:attribute (Results 1 - 200 of 1496) sorted by relevance

12345678

/linux-4.1.27/lib/
H A Dnlattr.c111 * @head: head of attribute stream
112 * @len: length of attribute stream
113 * @maxtype: maximum attribute type to be expected
116 * Validates all attributes in the specified attribute stream against the
170 * @maxtype: maximum attribute type to be expected
171 * @head: head of attribute stream
172 * @len: length of attribute stream
175 * Parses a stream of attributes and stores a pointer to each attribute in
176 * the tb array accessible via the attribute type. Attributes with a type
215 * nla_find - Find a specific attribute in a stream of attributes
216 * @head: head of attribute stream
217 * @len: length of attribute stream
218 * @attrtype: type of attribute to look for
220 * Returns the first attribute in the stream matching the specified type.
236 * nla_strlcpy - Copy string attribute payload into a sized buffer
238 * @nla: attribute to copy the string from
267 * nla_memcpy - Copy a netlink attribute into another memory area
269 * @src: netlink attribute to copy from
273 * attribute's payload. memcpy
290 * nla_memcmp - Compare an attribute with sized memory area
291 * @nla: netlink attribute
308 * nla_strcmp - Compare a string attribute against a string
309 * @nla: netlink string attribute
332 * __nla_reserve - reserve room for attribute on the skb
334 * @attrtype: attribute type
335 * @attrlen: length of attribute payload
337 * Adds a netlink attribute header to a socket buffer and reserves
341 * tailroom for the attribute header and payload.
358 * __nla_reserve_nohdr - reserve room for attribute without header
360 * @attrlen: length of attribute payload
362 * Reserves room for attribute payload without a header.
379 * nla_reserve - reserve room for attribute on the skb
381 * @attrtype: attribute type
382 * @attrlen: length of attribute payload
384 * Adds a netlink attribute header to a socket buffer and reserves
388 * the attribute header and payload.
400 * nla_reserve_nohdr - reserve room for attribute without header
402 * @attrlen: length of attribute payload
404 * Reserves room for attribute payload without a header.
407 * the attribute payload.
419 * __nla_put - Add a netlink attribute to a socket buffer
420 * @skb: socket buffer to add attribute to
421 * @attrtype: attribute type
422 * @attrlen: length of attribute payload
423 * @data: head of attribute payload
426 * tailroom for the attribute header and payload.
439 * __nla_put_nohdr - Add a netlink attribute without header
440 * @skb: socket buffer to add attribute to
441 * @attrlen: length of attribute payload
442 * @data: head of attribute payload
445 * tailroom for the attribute payload.
457 * nla_put - Add a netlink attribute to a socket buffer
458 * @skb: socket buffer to add attribute to
459 * @attrtype: attribute type
460 * @attrlen: length of attribute payload
461 * @data: head of attribute payload
464 * the attribute header and payload.
477 * nla_put_nohdr - Add a netlink attribute without header
478 * @skb: socket buffer to add attribute to
479 * @attrlen: length of attribute payload
480 * @data: head of attribute payload
483 * the attribute payload.
496 * nla_append - Add a netlink attribute without header or padding
497 * @skb: socket buffer to add attribute to
498 * @attrlen: length of attribute payload
499 * @data: head of attribute payload
502 * the attribute payload.
/linux-4.1.27/include/net/
H A Dnetlink.h65 * nlmsg_find_attr() find an attribute in a message
88 * struct nlattr netlink attribute header
91 * nla_reserve(skb, type, len) reserve room for an attribute
92 * nla_reserve_nohdr(skb, len) reserve room for an attribute w/o hdr
93 * nla_put(skb, type, len, data) add attribute to skb
94 * nla_put_nohdr(skb, len, data) add attribute w/o hdr
98 * nla_put_u8(skb, type, value) add u8 attribute to skb
99 * nla_put_u16(skb, type, value) add u16 attribute to skb
100 * nla_put_u32(skb, type, value) add u32 attribute to skb
101 * nla_put_u64(skb, type, value) add u64 attribute to skb
102 * nla_put_s8(skb, type, value) add s8 attribute to skb
103 * nla_put_s16(skb, type, value) add s16 attribute to skb
104 * nla_put_s32(skb, type, value) add s32 attribute to skb
105 * nla_put_s64(skb, type, value) add s64 attribute to skb
106 * nla_put_string(skb, type, str) add string attribute to skb
107 * nla_put_flag(skb, type) add flag attribute to skb
108 * nla_put_msecs(skb, type, jiffies) add msecs attribute to skb
109 * nla_put_in_addr(skb, type, addr) add IPv4 address attribute to skb
110 * nla_put_in6_addr(skb, type, addr) add IPv6 address attribute to skb
113 * nla_nest_start(skb, type) start a nested attribute
114 * nla_nest_end(skb, nla) finalize a nested attribute
115 * nla_nest_cancel(skb, nla) cancel nested attribute construction
118 * nla_attr_size(payload) length of attribute w/o padding
119 * nla_total_size(payload) length of attribute w/ padding
123 * nla_data(nla) head of attribute payload
124 * nla_len(nla) length of attribute payload
127 * nla_get_u8(nla) get payload for a u8 attribute
128 * nla_get_u16(nla) get payload for a u16 attribute
129 * nla_get_u32(nla) get payload for a u32 attribute
130 * nla_get_u64(nla) get payload for a u64 attribute
131 * nla_get_s8(nla) get payload for a s8 attribute
132 * nla_get_s16(nla) get payload for a s16 attribute
133 * nla_get_s32(nla) get payload for a s32 attribute
134 * nla_get_s64(nla) get payload for a s64 attribute
136 * nla_get_msecs(nla) get payload for a msecs attribute
139 * nla_memcpy(dest, nla, count) copy attribute into memory
140 * nla_memcmp(nla, data, size) compare attribute with memory area
141 * nla_strlcpy(dst, nla, size) copy attribute to a sized string
142 * nla_strcmp(nla, str) compare attribute with string
146 * nla_next(nla, remaining) get next netlink attribute
149 * nla_find() find attribute in stream of attributes
150 * nla_find_nested() find attribute in nested attributes
159 * Standard attribute types to specify validation policy
184 * struct nla_policy - attribute validation policy
185 * @type: Type of attribute or NLA_UNSPEC
189 * accessible by attribute type up to the highest identifier to be expected.
195 * NLA_BINARY Maximum length of attribute payload
206 * All other Minimum length of attribute payload
363 * @maxtype: maximum attribute type to be expected
380 * nlmsg_find_attr - find a specific attribute in a netlink message
383 * @attrtype: type of attribute to look for
385 * Returns the first attribute which matches the specified type.
398 * @maxtype: maximum attribute type to be expected
425 * @pos: loop counter, set to current attribute
630 * nla_attr_size - length of attribute not including padding
639 * nla_total_size - total length of attribute including padding
648 * nla_padlen - length of padding at the tail of attribute
657 * nla_type - attribute type
658 * @nla: netlink attribute
667 * @nla: netlink attribute
676 * @nla: netlink attribute
684 * nla_ok - check if the netlink attribute fits into the remaining bytes
685 * @nla: netlink attribute
686 * @remaining: number of bytes remaining in attribute stream
696 * nla_next - next netlink attribute in attribute stream
697 * @nla: netlink attribute
698 * @remaining: number of bytes remaining in attribute stream
700 * Returns the next netlink attribute in the attribute stream and
701 * decrements remaining by the size of the current attribute.
712 * nla_find_nested - find attribute in a set of nested attributes
713 * @nla: attribute containing the nested attributes
714 * @attrtype: type of attribute to look for
716 * Returns the first attribute which matches the specified type.
727 * @maxtype: maximum attribute type to be expected
728 * @nla: attribute containing the nested attributes
741 * nla_put_u8 - Add a u8 netlink attribute to a socket buffer
742 * @skb: socket buffer to add attribute to
743 * @attrtype: attribute type
752 * nla_put_u16 - Add a u16 netlink attribute to a socket buffer
753 * @skb: socket buffer to add attribute to
754 * @attrtype: attribute type
763 * nla_put_be16 - Add a __be16 netlink attribute to a socket buffer
764 * @skb: socket buffer to add attribute to
765 * @attrtype: attribute type
774 * nla_put_net16 - Add 16-bit network byte order netlink attribute to a socket buffer
775 * @skb: socket buffer to add attribute to
776 * @attrtype: attribute type
785 * nla_put_le16 - Add a __le16 netlink attribute to a socket buffer
786 * @skb: socket buffer to add attribute to
787 * @attrtype: attribute type
796 * nla_put_u32 - Add a u32 netlink attribute to a socket buffer
797 * @skb: socket buffer to add attribute to
798 * @attrtype: attribute type
807 * nla_put_be32 - Add a __be32 netlink attribute to a socket buffer
808 * @skb: socket buffer to add attribute to
809 * @attrtype: attribute type
818 * nla_put_net32 - Add 32-bit network byte order netlink attribute to a socket buffer
819 * @skb: socket buffer to add attribute to
820 * @attrtype: attribute type
829 * nla_put_le32 - Add a __le32 netlink attribute to a socket buffer
830 * @skb: socket buffer to add attribute to
831 * @attrtype: attribute type
840 * nla_put_u64 - Add a u64 netlink attribute to a socket buffer
841 * @skb: socket buffer to add attribute to
842 * @attrtype: attribute type
851 * nla_put_be64 - Add a __be64 netlink attribute to a socket buffer
852 * @skb: socket buffer to add attribute to
853 * @attrtype: attribute type
862 * nla_put_net64 - Add 64-bit network byte order netlink attribute to a socket buffer
863 * @skb: socket buffer to add attribute to
864 * @attrtype: attribute type
873 * nla_put_le64 - Add a __le64 netlink attribute to a socket buffer
874 * @skb: socket buffer to add attribute to
875 * @attrtype: attribute type
884 * nla_put_s8 - Add a s8 netlink attribute to a socket buffer
885 * @skb: socket buffer to add attribute to
886 * @attrtype: attribute type
895 * nla_put_s16 - Add a s16 netlink attribute to a socket buffer
896 * @skb: socket buffer to add attribute to
897 * @attrtype: attribute type
906 * nla_put_s32 - Add a s32 netlink attribute to a socket buffer
907 * @skb: socket buffer to add attribute to
908 * @attrtype: attribute type
917 * nla_put_s64 - Add a s64 netlink attribute to a socket buffer
918 * @skb: socket buffer to add attribute to
919 * @attrtype: attribute type
928 * nla_put_string - Add a string netlink attribute to a socket buffer
929 * @skb: socket buffer to add attribute to
930 * @attrtype: attribute type
940 * nla_put_flag - Add a flag netlink attribute to a socket buffer
941 * @skb: socket buffer to add attribute to
942 * @attrtype: attribute type
950 * nla_put_msecs - Add a msecs netlink attribute to a socket buffer
951 * @skb: socket buffer to add attribute to
952 * @attrtype: attribute type
963 * nla_put_in_addr - Add an IPv4 address netlink attribute to a socket
965 * @skb: socket buffer to add attribute to
966 * @attrtype: attribute type
976 * nla_put_in6_addr - Add an IPv6 address netlink attribute to a socket
978 * @skb: socket buffer to add attribute to
979 * @attrtype: attribute type
989 * nla_get_u32 - return payload of u32 attribute
990 * @nla: u32 netlink attribute
998 * nla_get_be32 - return payload of __be32 attribute
999 * @nla: __be32 netlink attribute
1007 * nla_get_u16 - return payload of u16 attribute
1008 * @nla: u16 netlink attribute
1016 * nla_get_be16 - return payload of __be16 attribute
1017 * @nla: __be16 netlink attribute
1025 * nla_get_le16 - return payload of __le16 attribute
1026 * @nla: __le16 netlink attribute
1034 * nla_get_u8 - return payload of u8 attribute
1035 * @nla: u8 netlink attribute
1043 * nla_get_u64 - return payload of u64 attribute
1044 * @nla: u64 netlink attribute
1056 * nla_get_be64 - return payload of __be64 attribute
1057 * @nla: __be64 netlink attribute
1069 * nla_get_s32 - return payload of s32 attribute
1070 * @nla: s32 netlink attribute
1078 * nla_get_s16 - return payload of s16 attribute
1079 * @nla: s16 netlink attribute
1087 * nla_get_s8 - return payload of s8 attribute
1088 * @nla: s8 netlink attribute
1096 * nla_get_s64 - return payload of s64 attribute
1097 * @nla: s64 netlink attribute
1109 * nla_get_flag - return payload of flag attribute
1110 * @nla: flag netlink attribute
1118 * nla_get_msecs - return payload of msecs attribute
1119 * @nla: msecs netlink attribute
1131 * nla_get_in_addr - return payload of IPv4 address attribute
1132 * @nla: IPv4 address netlink attribute
1140 * nla_get_in6_addr - return payload of IPv6 address attribute
1141 * @nla: IPv6 address netlink attribute
1154 * @attrtype: attribute type of container
1156 * Returns the container attribute
1171 * @start: container attribute
1173 * Corrects the container attribute header to include the all
1187 * @start: container attribute
1189 * Removes the container attribute and including all nested
1199 * @start: container attribute
1200 * @maxtype: maximum attribute type to be expected
1203 * Validates all attributes in the nested attribute stream against the
1217 * @pos: loop counter, set to current attribute
1218 * @head: head of attribute stream
1219 * @len: length of attribute stream
1229 * @pos: loop counter, set to current attribute
1230 * @nla: attribute containing the nested attributes
1237 * nla_is_last - Test if attribute is last in stream
1238 * @nla: attribute to test
H A Drtnetlink.h31 * @maxtype: Highest device specific netlink attribute number
32 * @policy: Netlink policy for device specific attribute validation
115 * @validate_link_af: Validate a IFLA_AF_SPEC attribute, must check attr
117 * @set_link_af: Function to parse a IFLA_AF_SPEC attribute and modify
/linux-4.1.27/tools/usb/usbip/libsrc/
H A Dsysfs_utils.c17 dbg("error opening attribute %s", attr_path); write_sysfs_attribute()
23 dbg("error writing to attribute %s", attr_path); write_sysfs_attribute()
/linux-4.1.27/include/uapi/linux/caif/
H A Dif_caif.h16 * The type of attribute is NLA_U32.
18 * The type of attribute is NLA_U32.
20 * The type of attribute is NLA_U8.
/linux-4.1.27/include/uapi/linux/
H A Dlimits.h14 #define XATTR_NAME_MAX 255 /* # chars in an extended attribute name */
15 #define XATTR_SIZE_MAX 65536 /* size of an extended attribute value (64k) */
16 #define XATTR_LIST_MAX 65536 /* size of extended attribute namelist (64k) */
H A Dncp_no.h4 /* these define the attribute byte as seen by NCP */
H A Dnl80211.h124 * the %NL80211_ATTR_SUPPORTED_IFTYPES attribute, but by listing the
133 * is exported in the %NL80211_ATTR_SOFTWARE_IFTYPES attribute.
136 * in the %NL80211_ATTR_INTERFACE_COMBINATIONS attribute. Basically,
209 * attribute %NL80211_ATTR_IFINDEX.
340 * using the %NL80211_ATTR_IE attribute. The first cycle of the
412 * included %NL80211_ATTR_FRAME attribute contains the management frame
415 * case the %NL80211_ATTR_FRAME attribute is replaced with a
439 * FREQ attribute (for the initial frequency if no peer can be found)
440 * and optionally a MAC (as BSSID) and FREQ_FIXED attribute if those
444 * given in the %NL80211_ATTR_BEACON_INTERVAL attribute, which if not
449 * @NL80211_CMD_TESTMODE: testmode command, takes a wiphy (or ifindex) attribute
450 * to identify the device, and the TESTDATA blob attribute to pass through
456 * %NL80211_ATTR_SSID attribute, and can optionally specify the association
475 * This attribute is ignored if driver does not support roam scan.
478 * determined by the STATUS_CODE attribute.
508 * radio. The %NL80211_ATTR_COOKIE attribute must be given as well to
519 * requires an interface index, a frame type attribute (optional for
521 * and a match attribute containing the first few bytes of the frame
544 * counters which will be updated to the current value. This attribute
607 * command with the %NL80211_ATTR_WOWLAN_TRIGGERS attribute. For
612 * @NL80211_ATTR_WOWLAN_TRIGGERS attribute will contain the reason
636 * %NL80211_ATTR_TDLS_ACTION attribute determines the type of frame to be
649 * For the event, the %NL80211_ATTR_MAC attribute carries the TA and
759 * by the %NL80211_ATTR_VENDOR_ID attribute and a sub-command in
762 * For feature advertisement, the %NL80211_ATTR_VENDOR_DATA attribute is
763 * used in the wiphy data as a nested attribute containing descriptions
769 * that attribute is not included, QoS mapping is disabled. Since this
779 * If the admitted time attribute is not added then the request just checks
1030 * @NL80211_ATTR_UNSPEC: unspecified attribute to catch errors
1038 * %NL80211_ATTR_WIPHY_CHANNEL_TYPE attribute or the attributes
1041 * @NL80211_ATTR_CHANNEL_WIDTH: u32 attribute containing one of the values
1051 * this attribute)
1055 * This attribute is now deprecated.
1088 * @NL80211_ATTR_KEY_DEFAULT: Flag attribute indicating the key is default key
1089 * @NL80211_ATTR_KEY_DEFAULT_MGMT: Flag attribute indicating the key is the
1112 * given for %NL80211_CMD_GET_STATION, nested attribute containing
1123 * info given for %NL80211_CMD_GET_MPATH, nested attribute described at
1131 * For example, 'CR', for Costa Rica. This attribute is used by the kernel
1132 * to query the CRDA to retrieve one regulatory domain. This attribute can
1153 * @NL80211_ATTR_SUPPORTED_IFTYPES: nested attribute containing all
1154 * supported interface types, each a flag attribute with the number
1164 * a single scan request, a wiphy attribute.
1166 * scan with a single scheduled scan request, a wiphy attribute.
1172 * used with @NL80211_ATTR_SCHED_SCAN_MATCH, a wiphy attribute.
1174 * @NL80211_ATTR_SCAN_FREQUENCIES: nested attribute with frequencies (in MHz)
1175 * @NL80211_ATTR_SCAN_SSIDS: nested attribute with SSIDs, leave out for passive
1184 * @NL80211_ATTR_SUPPORTED_COMMANDS: wiphy attribute that specifies
1188 * @NL80211_ATTR_FRAME: frame data (binary attribute), including frame header
1191 * @NL80211_ATTR_SSID: SSID (binary attribute, 0..32 octets)
1201 * due to considerations from a beacon hint. This attribute reflects
1203 * attributes consists of a nested attribute containing
1206 * due to considerations from a beacon hint. This attribute reflects
1208 * attributes consists of a nested attribute containing
1222 * this attribute can be used
1238 * attribute is also used as a flag in the wiphy information to
1252 * @NL80211_ATTR_PRIVACY: Flag attribute, used with connect(), indicating
1276 * @NL80211_ATTR_KEY: key information in a nested attribute with
1279 * and join_ibss(), key information is in a nested attribute each
1295 * the survey response for %NL80211_CMD_GET_SURVEY, nested attribute
1300 * cache, a wiphy attribute.
1303 * @NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION: Device attribute that
1313 * rates based on negotiated supported rates information. This attribute
1316 * @NL80211_ATTR_FRAME_MATCH: A binary attribute which typically must contain
1320 * @NL80211_ATTR_TX_FRAME_TYPES: wiphy capability attribute, which is a
1321 * nested attribute of %NL80211_ATTR_FRAME_TYPE attributes, containing
1324 * @NL80211_ATTR_RX_FRAME_TYPES: wiphy capability attribute, which is a
1325 * nested attribute of %NL80211_ATTR_FRAME_TYPE attributes, containing
1328 * @NL80211_ATTR_ACK: Flag attribute indicating that the frame was
1334 * nested attribute with %NL80211_ATTR_CQM_* sub-attributes.
1336 * @NL80211_ATTR_LOCAL_STATE_CHANGE: Flag attribute to indicate that a command
1392 * @NL80211_ATTR_KEY_DEFAULT_TYPES: A nested attribute containing flags
1398 * @NL80211_ATTR_MESH_CONFIG: Mesh configuration parameters, a nested attribute
1418 * @NL80211_ATTR_SCHED_SCAN_MATCH: Nested attribute with one or more
1436 * @NL80211_ATTR_INTERFACE_COMBINATIONS: Nested attribute listing the supported
1439 * @NL80211_ATTR_SOFTWARE_IFTYPES: Nested attribute (just like
1444 * @NL80211_ATTR_REKEY_DATA: nested attribute containing the information
1448 * nested array attribute containing an entry for each band, with the entry
1466 * @NL80211_ATTR_STA_WME: Nested attribute containing the wme configuration
1474 * @NL80211_ATTR_PMKSA_CANDIDATE: Nested attribute containing the PMKSA caching
1480 * applications use this attribute.
1481 * This attribute is used with %NL80211_CMD_TRIGGER_SCAN and
1498 * @NL80211_ATTR_DEVICE_AP_SME: This u32 attribute may be listed for devices
1500 * with support for the features listed in this attribute, see
1508 * @NL80211_ATTR_FEATURE_FLAGS: This u32 attribute contains flags from
1512 * This attribute holds a bitmap of the supported protocols for
1544 * this attribute is (depending on the driver capabilities) added to
1579 * carried in a u32 attribute
1584 * @NL80211_ATTR_MAC_ACL_MAX: u32 attribute to advertise the maximum
1605 * &enum nl80211_protocol_features, the attribute is a u32.
1607 * @NL80211_ATTR_SPLIT_WIPHY_DUMP: flag attribute, userspace supports
1628 * @NL80211_ATTR_CH_SWITCH_COUNT: u32 attribute specifying the number of TBTT's
1630 * @NL80211_ATTR_CH_SWITCH_BLOCK_TX: flag attribute specifying that transmission
1662 * %NL80211_CMD_NEW_STATION; u8 attribute.
1668 * attribute is also used for vendor command feature advertisement
1679 * @NL80211_ATTR_MAX_AP_ASSOC_STA: Device attribute that indicates how many
1688 * @NL80211_ATTR_MAX_CSA_COUNTERS: U8 attribute used to advertise the maximum
1694 * @NL80211_ATTR_SOCKET_OWNER: Flag attribute, if set during interface
1705 * @NL80211_ATTR_TDLS_INITIATOR: flag attribute indicating the current end is
1709 * shall support Radio Resource Measurements (11k). This attribute can be
1719 * @NL80211_ATTR_WIPHY_DYN_ACK: flag attribute used to enable ACK timeout
1725 * @NL80211_ATTR_TSID: a TSID value (u8 attribute)
1726 * @NL80211_ATTR_USER_PRIO: user priority value (u8 attribute)
1728 * (per second) (u16 attribute)
1737 * @NL80211_ATTR_WIPHY_SELF_MANAGED_REG: flag attribute indicating this device
1761 * @NL80211_ATTR_REG_INDOOR: flag attribute, if set indicates that the device
1765 * @NL80211_ATTR_MAX: highest attribute number currently defined
2243 * @__NL80211_STA_FLAG_INVALID: attribute number 0 is reserved
2293 * These attribute types are used with %NL80211_STA_INFO_TXRATE
2299 * (>6.5535Gbps) only 32-bit attribute is included.
2300 * User space tools encouraged to use the 32-bit attribute and fall
2303 * @__NL80211_RATE_INFO_INVALID: attribute number 0 is reserved
2347 * These attribute types are used with %NL80211_STA_INFO_BSS_PARAM
2350 * @__NL80211_STA_BSS_PARAM_INVALID: attribute number 0 is reserved
2377 * These attribute types are used with %NL80211_ATTR_STA_INFO
2380 * @__NL80211_STA_INFO_INVALID: attribute number 0 is reserved
2391 * @NL80211_STA_INFO_TX_BITRATE: current unicast tx rate, nested attribute
2406 * attribute, like NL80211_STA_INFO_TX_BITRATE.
2407 * @NL80211_STA_INFO_BSS_PARAM: current station's view of BSS, nested attribute
2429 * This is a nested attribute where each the inner attribute number is the
2434 * @NL80211_STA_INFO_MAX: highest possible station info attribute
2477 * @__NL80211_TID_STATS_INVALID: attribute number 0 is reserved
2486 * @NL80211_TID_STATS_MAX: highest numbered attribute here
2520 * These attribute types are used with %NL80211_ATTR_MPATH_INFO when getting
2523 * @__NL80211_MPATH_INFO_INVALID: attribute number 0 is reserved
2532 * @NL80211_MPATH_INFO_MAX: highest mesh path information attribute number
2553 * @__NL80211_BAND_ATTR_INVALID: attribute number 0 is reserved
2558 * @NL80211_BAND_ATTR_HT_MCS_SET: 16-byte attribute containing the MCS set as
2563 * @NL80211_BAND_ATTR_VHT_MCS_SET: 32-byte attribute containing the MCS set as
2566 * @NL80211_BAND_ATTR_MAX: highest band attribute currently defined
2591 * @__NL80211_FREQUENCY_ATTR_INVALID: attribute number 0 is reserved
2618 * channel. A channel that has the INDOOR_ONLY attribute can only be
2627 * channel that has the GO_CONCURRENT attribute set can be done when there
2637 * @NL80211_FREQUENCY_ATTR_MAX: highest frequency attribute number
2678 * @__NL80211_BITRATE_ATTR_INVALID: attribute number 0 is reserved
2682 * @NL80211_BITRATE_ATTR_MAX: highest bitrate attribute number
2744 * @__NL80211_REG_RULE_ATTR_INVALID: attribute number 0 is reserved
2763 * @NL80211_REG_RULE_ATTR_MAX: highest regulatory rule attribute number
2787 * @__NL80211_SCHED_SCAN_MATCH_ATTR_INVALID: attribute number 0 is reserved
2792 * if this attribute is in a match set of its own, then it is treated as
2797 * attribute) is if there's only a single matchset with the RSSI attribute.
2799 * attribute number currently defined
2885 * assumed if the attribute is not set.
2907 * These attribute types are used with %NL80211_ATTR_SURVEY_INFO
2910 * @__NL80211_SURVEY_INFO_INVALID: attribute number 0 is reserved
2926 * @NL80211_SURVEY_INFO_MAX: highest survey info attribute number
3098 * @NL80211_MESHCONF_ATTR_MAX: highest possible mesh configuration attribute
3204 * @NL80211_MESH_SETUP_ATTR_MAX: highest possible mesh setup attribute number
3236 * @NL80211_TXQ_ATTR_MAX: Maximum TXQ attribute number
3286 * attribute.
3291 * attribute must be provided as well
3293 * attribute must be provided as well
3297 * attribute must be provided as well
3315 * These values are used with the %NL80211_BSS_CHAN_WIDTH attribute.
3339 * @NL80211_BSS_INFORMATION_ELEMENTS: binary attribute containing the
3341 * if the %NL80211_BSS_BEACON_IES attribute is present and the data is
3346 * If present, the @NL80211_BSS_PRESP_DATA attribute indicates that the
3354 * @NL80211_BSS_BEACON_IES: binary attribute containing the raw information
3362 * @NL80211_BSS_TSF is known to be from a probe response (flag attribute)
3364 * @NL80211_BSS_MAX: highest BSS attribute
3397 * The BSS status is a BSS attribute in scan dumps, which
3418 * the attribute for this on CONNECT commands.
3496 * @NL80211_KEY_DEFAULT_TYPES: A nested attribute containing flags
3500 * @NL80211_KEY_MAX: highest key attribute
3531 * @NL80211_TXRATE_MAX: highest TX rate attribute
3607 * @NL80211_ATTR_CQM_BEACON_LOSS_EVENT: flag attribute that's set in a beacon
3610 * @NL80211_ATTR_CQM_MAX: highest key attribute
3656 * enum nl80211_packet_pattern_attr - packet pattern attribute
3657 * @__NL80211_PKTPAT_INVALID: invalid number for nested attribute
3674 * @MAX_NL80211_PKTPAT: max attribute number
3728 * which are passed in an array of nested attributes, each nested attribute
3735 * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute
3738 * When reporting wakeup. it is a u32 attribute containing the 0-based
3754 * attribute contains the original length.
3757 * attribute if the packet was truncated somewhere.
3760 * be truncated, the @NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023_LEN attribute
3764 * attribute if the packet was truncated somewhere.
3766 * "TCP connection wakeup" for more details. This is a nested attribute
3777 * is detected. This is a nested attribute that contains the
3782 * attribute is also sent in a response to
3785 * @NL80211_WOWLAN_TRIG_NET_DETECT_RESULTS: nested attribute
3791 * Each element in the array is a nested attribute that contains
3792 * one optional %NL80211_ATTR_SSID attribute and one optional
3793 * %NL80211_ATTR_SCAN_FREQUENCIES attribute. At least one of
3799 * @MAX_NL80211_WOWLAN_TRIG: highest wowlan trigger attribute number
3904 * For feature advertising, a u32 attribute holding the maximum length
3915 * u32 attribute holding the maximum length
3920 * @MAX_NL80211_WOWLAN_TCP: highest attribute number
3957 * enum nl80211_attr_coalesce_rule - coalesce rule attribute
3958 * @__NL80211_COALESCE_RULE_INVALID: invalid number for nested attribute
3965 * @NL80211_ATTR_COALESCE_RULE_MAX: max attribute number
3995 * @NL80211_IFACE_LIMIT_TYPES: nested attribute containing a
3996 * flag attribute for each interface type in this set
3998 * @MAX_NL80211_IFACE_LIMIT: highest attribute number
4016 * @NL80211_IFACE_COMB_MAXNUM: u32 attribute giving the total number of
4019 * in a separate attribute %NL80211_ATTR_INTERFACES_SOFTWARE.
4020 * @NL80211_IFACE_COMB_STA_AP_BI_MATCH: flag attribute specifying that
4024 * @NL80211_IFACE_COMB_NUM_CHANNELS: u32 attribute specifying how many
4026 * @NL80211_IFACE_COMB_RADAR_DETECT_WIDTHS: u32 attribute containing the bitmap
4028 * @NL80211_IFACE_COMB_RADAR_DETECT_REGIONS: u32 attribute containing the bitmap
4031 * @MAX_NL80211_IFACE_COMB: highest attribute number
4047 * within the %NL80211_ATTR_INTERFACE_COMBINATIONS attribute to indicate
4131 * @MAX_NL80211_REKEY_DATA: highest rekey attribute (internal)
4161 * @__NL80211_STA_WME_INVALID: invalid number for nested attribute
4167 * @NL80211_STA_WME_MAX: highest station WME attribute
4188 * @MAX_NL80211_PMKSA_CANDIDATE: highest PMKSA caching candidate attribute
4288 * estimation (dynack). %NL80211_ATTR_WIPHY_DYN_ACK flag attribute is used
4372 * To be used with the %NL80211_ATTR_PROBE_RESP_OFFLOAD attribute.
4411 * as AP and the beaconing has already been configured. This attribute is
4511 * wiphy dumps (if requested by the application with the attribute
H A Dnetlink_diag.h36 /* NETLINK_DIAG_NONE, standard nl API requires this attribute! */
H A Dunix_diag.h34 /* UNIX_DIAG_NONE, standard nl API requires this attribute! */
H A Dif_addr.h20 * local address is supplied in IFA_LOCAL attribute.
22 * IFA_FLAGS is a u32 attribute that extends the u8 field ifa_flags.
H A Dip_vs.h328 IPVS_CMD_ATTR_SERVICE, /* nested service attribute */
329 IPVS_CMD_ATTR_DEST, /* nested destination attribute */
330 IPVS_CMD_ATTR_DAEMON, /* nested sync daemon attribute */
342 * Used inside nested attribute IPVS_CMD_ATTR_SERVICE
357 IPVS_SVC_ATTR_STATS, /* nested attribute for service stats */
361 IPVS_SVC_ATTR_STATS64, /* nested attribute for service stats */
371 * Used inside nested attribute IPVS_CMD_ATTR_DEST
388 IPVS_DEST_ATTR_STATS, /* nested attribute for dest stats */
392 IPVS_DEST_ATTR_STATS64, /* nested attribute for dest stats */
402 * Used inside nested attribute IPVS_CMD_ATTR_DAEMON
H A Dpacket_diag.h32 /* PACKET_DIAG_NONE, standard nl API requires this attribute! */
H A Dirda.h93 #define IRLMP_IAS_SET 2 /* Set an attribute in local IAS */
94 #define IRLMP_IAS_QUERY 3 /* Query remote IAS for attribute */
99 #define IRLMP_IAS_GET 8 /* Get an attribute from local IAS */
100 #define IRLMP_IAS_DEL 9 /* Remove attribute from local IAS */
159 } attribute; member in struct:irda_ias_set
H A Ddcbnl.h335 * @DCB_ATTR_UNDEFINED: unspecified attribute to catch errors
461 * @DCB_PFC_UP_ATTR_UNDEFINED: unspecified attribute to catch errors
470 * @DCB_PFC_UP_ATTR_MAX: highest attribute number currently defined
494 * @DCB_PG_ATTR_UNDEFINED: unspecified attribute to catch errors
503 * @DCB_PG_ATTR_TC_MAX: highest attribute number currently defined
513 * @DCB_PG_ATTR_BW_ID_MAX: highest attribute number currently defined
549 * @DCB_TC_ATTR_PARAM_UNDEFINED: unspecified attribute to catch errors
582 * @DCB_CAP_ATTR_UNDEFINED: unspecified attribute to catch errors
651 * @DCB_NUMTCS_ATTR_UNDEFINED: unspecified attribute to catch errors
703 * enum dcb_general_attr_values - general DCB attribute values
705 * @DCB_ATTR_UNDEFINED: value used to indicate an attribute is not supported
728 * @DCB_FEATCFG_ATTR_UNDEFINED: unspecified attribute to catch errors
H A Dgfs2_ondisk.h286 __be64 di_eattr; /* extended attribute block number */
341 * Extended attribute header format
352 * extended attribute headers themselves all start with the common
354 * have either a single block containing the extended attribute headers
356 * extended attribute headers.
358 * The maximum size of the data part of an extended attribute is 64k
H A Dbsg.h30 __u32 request_attr; /* [i] {SCSI: task attribute} */
H A Dmsdos_fs.h33 #define ATTR_NONE 0 /* no attribute bits */
41 /* attribute bits that are copied "as is" */
176 __u8 attr; /* attribute bits */
191 __u8 attr; /* attribute byte */
H A Dnetdevice.h40 /* interface name assignment types (sysfs name_assign_type attribute) */
H A Dopenvswitch.h118 /* Allow last Netlink attribute to be unaligned */
158 * %OVS_USERSPACE_ATTR_USERDATA attribute, with the same length and content
162 * %OVS_USERSPACE_ATTR_EGRESS_TUN_PORT attribute, which is sent only if the
459 * a wildcarded match. Omitting attribute is treated as wildcarding all
464 * than the value of the %OVS_FLOW_ATTR_KEY attribute. Optional for all
466 * attribute.
600 * single nested %OVS_KEY_ATTR_* attribute specifies a header to modify and its
603 * nested %OVS_KEY_ATTR_* attribute specifies a header to modify, its value,
607 * Masking is not supported for the %OVS_KEY_ATTR_TUNNEL attribute.
/linux-4.1.27/include/linux/iio/
H A Dsysfs.h18 * struct iio_dev_attr - iio specific device attribute
19 * @dev_attr: underlying device attribute
38 * struct iio_const_attr - constant device specific attribute
40 * @string: attribute string
41 * @dev_attr: underlying device attribute
80 * @_show: output method for the attribute
81 * @_store: input method for the attribute
88 * @_show: output method for the attribute
96 * @_string: frequency string for the attribute
105 * @_show: output method for the attribute
111 * @_string: frequency string for the attribute
H A Diio.h65 * struct iio_chan_spec_ext_info - Extended channel info attribute
66 * @name: Info attribute name
67 * @shared: Whether this attribute is shared between all channels.
68 * @read: Read callback for this info attribute, may be NULL.
69 * @write: Write callback for this info attribute, may be NULL.
84 * struct iio_enum - Enum channel info attribute
95 * the attribute is updated. The last parameter is the index to the newly
115 * IIO_ENUM() - Initialize enum extended channel attribute
117 * @_shared: Whether the attribute is shared between all channels
132 * IIO_ENUM_AVAILABLE() - Initialize enum available extended channel attribute
136 * Creates a read only attribute which lists all the available enum items in a
254 * iio_channel_has_info() - Checks whether a channel supports a info attribute
256 * @type: Type of the info attribute to be checked
259 * attribute type, false otherwise.
468 * @groups: [INTERN] attribute groups
469 * @groupcounter: [INTERN] index of next attribute group
/linux-4.1.27/include/linux/
H A Ddma-attrs.h9 * an enum dma_attr represents an attribute associated with a DMA
10 * mapping. The semantics of each attribute should be defined in
46 * dma_set_attr - set a specific attribute
47 * @attr: attribute to set
59 * dma_get_attr - check for a specific attribute
60 * @attr: attribute to set
H A Dsysfs.h29 struct attribute { struct
40 * sysfs_attr_init - initialize a dynamically allocated sysfs attribute
41 * @attr: struct attribute to initialize
43 * Initialize a dynamically allocated struct attribute so we can
46 * Lockdep gives a nice error when your attribute is added to
61 * struct attribute_group - data structure used to declare an attribute group.
63 * If specified, the attribute group will be created in
66 * attribute of the group. Will be called repeatedly for each
67 * attribute in the group. Only read/write permissions as well as
68 * SYSFS_PREALLOC are accepted. Must return 0 if an attribute is
70 * defined in struct attribute or struct bin_attribute.
78 struct attribute *, int);
79 struct attribute **attrs;
146 struct attribute attr;
164 * enabled. Lockdep gives a nice error when your attribute is
200 ssize_t (*show)(struct kobject *, struct attribute *, char *);
201 ssize_t (*store)(struct kobject *, struct attribute *, const char *, size_t);
219 const struct attribute *attr,
222 const struct attribute **attr);
224 const struct attribute *attr, umode_t mode);
225 void sysfs_remove_file_ns(struct kobject *kobj, const struct attribute *attr,
227 bool sysfs_remove_file_self(struct kobject *kobj, const struct attribute *attr);
228 void sysfs_remove_files(struct kobject *kobj, const struct attribute **attr);
260 const struct attribute *attr, const char *group);
262 const struct attribute *attr, const char *group);
317 const struct attribute *attr, sysfs_create_file_ns()
324 const struct attribute **attr) sysfs_create_files()
330 const struct attribute *attr, umode_t mode) sysfs_chmod_file()
336 const struct attribute *attr, sysfs_remove_file_ns()
342 const struct attribute *attr) sysfs_remove_file_self()
348 const struct attribute **attr) sysfs_remove_files()
421 const struct attribute *attr, const char *group) sysfs_add_file_to_group()
427 const struct attribute *attr, const char *group) sysfs_remove_file_from_group()
471 const struct attribute *attr) sysfs_create_file()
477 const struct attribute *attr) sysfs_remove_file()
H A Dmbus.h24 * The base address, size, and MBUS attribute ID for each
68 unsigned int attribute,
71 int mvebu_mbus_add_window_by_id(unsigned int target, unsigned int attribute,
H A Dhid-sensor-hub.h30 * @attrib_id: Attribute id for this attribute.
33 * @units: Measurment unit for this attribute.
36 * @logical_minimum: Logical minimum value for this attribute.
37 * @logical_maximum: Logical maximum value for this attribute.
158 * sensor_hub_input_get_attribute_info() - Get an attribute information
160 * @type: Type of this attribute, input/output/feature
163 * @info: return information about attribute after parsing report
165 * Parses report and returns the attribute information such as report id,
181 * Issues a synchronous or asynchronous read request for an input attribute.
H A Dposix_acl_xattr.h4 Extended attribute system call representation of Access Control Lists.
14 /* Extended attribute names */
H A Dbug.h63 * attribute just for this type of case. Thus, we use a negative sized array
65 * an undefined function with the error attribute (should always create an
H A Doid_registry.h65 /* Distinguished Name attribute IDs [RFC 2256] */
H A Dconfigfs.h131 * Users often need to create attribute structures for their configurable
133 * for the show() and store() operations on that attribute. If they don't
134 * need anything else on the extended attribute structure, they can use
146 * With the extended attribute structure, users can use this macro
H A Ddrbd_genl_api.h11 * the minor value shall be (~0), and the attribute DRBD_NLA_CFG_CONTEXT
H A Dgenl_magic_struct.h26 * Extension of genl attribute validation policies {{{2
32 * attribute must not be ignored.
35 * validating the attribute types and lengths via nla_parse_nested().
43 * @DRBD_F_REQUIRED: Attribute is required; a request without this attribute is
H A Dnfs_fs.h134 * to be valid. A successful attribute revalidation doubles
150 /* "Generation counter" for the attribute cache. This is
311 * nfs_save_change_attribute - Returns the inode attribute change cookie
313 * The "change attribute" is updated every time we finish an operation
324 * @chattr - previously saved change attribute
325 * Return "false" if the verifiers doesn't match the change attribute.
/linux-4.1.27/sound/pci/asihpi/
H A Dhpicmn.c334 if (phm->u.c.attribute == HPI_METER_PEAK) { hpi_check_control_cache_single()
337 } else if (phm->u.c.attribute == HPI_METER_RMS) { hpi_check_control_cache_single()
354 if (phm->u.c.attribute == HPI_VOLUME_GAIN) { hpi_check_control_cache_single()
357 } else if (phm->u.c.attribute == HPI_VOLUME_MUTE) { hpi_check_control_cache_single()
374 if (phm->u.c.attribute == HPI_MULTIPLEXER_SOURCE) { hpi_check_control_cache_single()
382 if (phm->u.c.attribute == HPI_CHANNEL_MODE_MODE) hpi_check_control_cache_single()
388 if (phm->u.c.attribute == HPI_LEVEL_GAIN) { hpi_check_control_cache_single()
395 if (phm->u.c.attribute == HPI_TUNER_FREQ) hpi_check_control_cache_single()
397 else if (phm->u.c.attribute == HPI_TUNER_BAND) hpi_check_control_cache_single()
399 else if (phm->u.c.attribute == HPI_TUNER_LEVEL_AVG) hpi_check_control_cache_single()
412 if (phm->u.c.attribute == HPI_AESEBURX_ERRORSTATUS) hpi_check_control_cache_single()
414 else if (phm->u.c.attribute == HPI_AESEBURX_FORMAT) hpi_check_control_cache_single()
420 if (phm->u.c.attribute == HPI_AESEBUTX_FORMAT) hpi_check_control_cache_single()
426 if (phm->u.c.attribute == HPI_TONEDETECTOR_STATE) hpi_check_control_cache_single()
432 if (phm->u.c.attribute == HPI_SILENCEDETECTOR_STATE) { hpi_check_control_cache_single()
438 if (phm->u.c.attribute == HPI_MICROPHONE_PHANTOM_POWER) hpi_check_control_cache_single()
444 if (phm->u.c.attribute == HPI_SAMPLECLOCK_SOURCE) hpi_check_control_cache_single()
446 else if (phm->u.c.attribute == HPI_SAMPLECLOCK_SOURCE_INDEX) { hpi_check_control_cache_single()
454 } else if (phm->u.c.attribute == HPI_SAMPLECLOCK_SAMPLERATE) hpi_check_control_cache_single()
465 attribute)))) { hpi_check_control_cache_single()
471 if (phm->u.c.attribute == HPI_PAD_PROGRAM_ID) hpi_check_control_cache_single()
473 else if (phm->u.c.attribute == HPI_PAD_PROGRAM_TYPE) hpi_check_control_cache_single()
478 attribute) - 1; hpi_check_control_cache_single()
526 phm->u.c.attribute); hpi_check_control_cache_single()
569 if (phm->u.c.attribute == HPI_VOLUME_GAIN) { hpi_cmn_control_cache_sync_to_msg_single()
572 } else if (phm->u.c.attribute == HPI_VOLUME_MUTE) { hpi_cmn_control_cache_sync_to_msg_single()
581 if (phm->u.c.attribute == HPI_MULTIPLEXER_SOURCE) { hpi_cmn_control_cache_sync_to_msg_single()
588 if (phm->u.c.attribute == HPI_CHANNEL_MODE_MODE) hpi_cmn_control_cache_sync_to_msg_single()
592 if (phm->u.c.attribute == HPI_LEVEL_GAIN) { hpi_cmn_control_cache_sync_to_msg_single()
598 if (phm->u.c.attribute == HPI_MICROPHONE_PHANTOM_POWER) hpi_cmn_control_cache_sync_to_msg_single()
602 if (phm->u.c.attribute == HPI_AESEBUTX_FORMAT) hpi_cmn_control_cache_sync_to_msg_single()
606 if (phm->u.c.attribute == HPI_AESEBURX_FORMAT) hpi_cmn_control_cache_sync_to_msg_single()
610 if (phm->u.c.attribute == HPI_SAMPLECLOCK_SOURCE) hpi_cmn_control_cache_sync_to_msg_single()
612 else if (phm->u.c.attribute == HPI_SAMPLECLOCK_SOURCE_INDEX) hpi_cmn_control_cache_sync_to_msg_single()
614 else if (phm->u.c.attribute == HPI_SAMPLECLOCK_SAMPLERATE) hpi_cmn_control_cache_sync_to_msg_single()
H A Dhpifunc.c1317 hm.u.c.attribute = attrib; hpi_control_param_set()
1334 hm.u.c.attribute = attrib; hpi_control_log_set2()
1352 hm.u.c.attribute = attrib; hpi_control_param_get()
1378 hm.u.c.attribute = attrib; hpi_control_log_get2()
1399 hm.u.c.attribute = attrib; hpi_control_query()
1409 static u16 hpi_control_get_string(const u32 h_control, const u16 attribute, hpi_control_get_string() argument
1429 hm.u.c.attribute = attribute; hpi_control_get_string()
1511 hm.u.c.attribute = HPI_AESEBURX_USERDATA; hpi_aesebu_receiver_get_user_data()
1530 hm.u.c.attribute = HPI_AESEBURX_CHANNELSTATUS; hpi_aesebu_receiver_get_channel_status()
1627 hm.u.c.attribute = HPI_BITSTREAM_ACTIVITY; hpi_bitstream_get_activity()
1679 hm.p.attribute = HPI_COBRANET_SET; hpi_cobranet_hmi_write()
1705 hm.p.attribute = HPI_COBRANET_GET; hpi_cobranet_hmi_read()
1737 hm.u.c.attribute = HPI_COBRANET_GET_STATUS; hpi_cobranet_hmi_get_status()
1923 hm.u.c.attribute = HPI_COMPANDER_THRESHOLD; hpi_compander_set_threshold()
1942 hm.u.c.attribute = HPI_COMPANDER_THRESHOLD; hpi_compander_get_threshold()
1973 hm.u.c.attribute = HPI_LEVEL_RANGE; hpi_level_query_range()
2023 hm.u.c.attribute = HPI_METER_PEAK; hpi_meter_get_peak()
2048 hm.u.c.attribute = HPI_METER_RMS; hpi_meter_get_rms()
2156 hm.u.c.attribute = HPI_MULTIPLEXER_QUERYSOURCE; hpi_multiplexer_query_source()
2200 hm.u.c.attribute = HPI_EQUALIZER_FILTER; hpi_parametric_eq_get_band()
2232 hm.u.c.attribute = HPI_EQUALIZER_FILTER; hpi_parametric_eq_set_band()
2249 hm.u.c.attribute = HPI_EQUALIZER_COEFFICIENTS; hpi_parametric_eq_get_coeffs()
2566 hm.u.cu.attribute = HPI_TUNER_LEVEL_AVG; hpi_tuner_get_rf_level()
2582 hm.u.cu.attribute = HPI_TUNER_LEVEL_RAW; hpi_tuner_get_raw_rf_level()
2695 hm.u.c.attribute = HPI_TUNER_RDS; hpi_tuner_get_rds()
2781 hm.u.c.attribute = HPI_VOLUME_RANGE; hpi_volume_query_range()
2813 hm.u.c.attribute = HPI_VOLUME_AUTOFADE; hpi_volume_auto_fade_profile()
2847 hm.u.c.attribute = HPI_VOX_THRESHOLD; hpi_vox_set_threshold()
2864 hm.u.c.attribute = HPI_VOX_THRESHOLD; hpi_vox_get_threshold()
H A Dhpidebug.c53 phm->u.c.attribute); hpi_debug_message()
/linux-4.1.27/arch/sh/include/mach-se/mach/
H A Dmrshpc.h30 /* attribute window open */ mrshpc_setup_windows()
33 /* attribute mode & bus width 16bit SWAP = 1*/ mrshpc_setup_windows()
36 /* attribute mode & bus width 16bit SWAP = 0*/ mrshpc_setup_windows()
H A Dse7751.h42 #define PA_MRSHPC_MW2 0xb8500000 /* MR-SHPC-01 attribute window base */
/linux-4.1.27/fs/ntfs/
H A Dattrib.c2 * attrib.c - NTFS attribute operations. Part of the Linux-NTFS project.
42 * @ctx: active attribute search context if present or NULL if not
54 * attribute on return as on entry. However, the actual pointers in @ctx may
68 * the attribute has zero allocated size, i.e. there simply is no runlist.
128 * If we already have the attribute extent containing @vcn in ntfs_map_runlist_nolock()
132 * the right attribute extent. ntfs_map_runlist_nolock()
159 * needed attribute extent. ntfs_map_runlist_nolock()
199 * If there is no attribute list, restoring the search context ntfs_map_runlist_nolock()
201 * the caller supplied context. If there is an attribute list, ntfs_map_runlist_nolock()
313 * @ni: ntfs inode of the attribute whose runlist to search
317 * Find the virtual cluster number @vcn in the runlist of the ntfs attribute
321 * If the @vcn is not mapped yet, the attempt is made to map the attribute
411 * @ctx: active attribute search context if present or NULL if not
416 * If the @vcn is not mapped yet, the attempt is made to map the attribute
427 * attribute on return as on entry. However, the actual pointers in @ctx may
533 * ntfs_attr_find - find (next) attribute in mft record
534 * @type: attribute type to find
535 * @name: attribute name to find (optional, i.e. NULL means don't care)
536 * @name_len: attribute name length (only needed if @name present)
538 * @val: attribute value to find (optional, resident attributes only)
539 * @val_len: attribute value length
540 * @ctx: search context with mft record and attribute to search from
547 * attribute of @type, optionally @name and @val.
549 * If the attribute is found, ntfs_attr_find() returns 0 and @ctx->attr will
550 * point to the found attribute.
552 * If the attribute is not found, ntfs_attr_find() returns -ENOENT and
553 * @ctx->attr will point to the attribute before which the attribute being
569 * If @name is not present (NULL), we assume that the unnamed attribute is
572 * Finally, the resident attribute value @val is looked for, if present. If
576 * presence of an attribute list attribute (unless it is the one being searched
577 * for, obviously). If you need to take attribute lists into consideration,
581 * attribute list attribute only. - Note that it is possible that the first
582 * extent is only in the attribute list while the last extent is in the base
586 * Warning: Never use @val when looking for attribute types which can be
600 * attribute following that, if @ctx->is_first is 'true'. ntfs_attr_find()
622 * missing, assume we want an unnamed attribute. ntfs_attr_find()
625 /* The search failed if the found attribute is named. */ ntfs_attr_find()
640 * matching attribute. ntfs_attr_find()
658 * The names match or @name not present and attribute is ntfs_attr_find()
659 * unnamed. If no @val specified, we have found the attribute ntfs_attr_find()
673 * If @val collates before the current attribute's ntfs_attr_find()
674 * value, there is no matching attribute. ntfs_attr_find()
695 * load_attribute_list - load an attribute list into memory
697 * @runlist: runlist of the attribute list
700 * @initialized_size: initialized size of the attribute list
738 ntfs_error(sb, "Cannot read attribute list since runlist is " load_attribute_list()
748 /* The attribute list cannot be sparse. */ load_attribute_list()
751 "read attribute list."); load_attribute_list()
764 "read attribute list."); load_attribute_list()
787 * Note: The attribute list can be smaller than its allocation load_attribute_list()
800 ntfs_error(sb, "Attribute list buffer overflow. Read attribute list " load_attribute_list()
808 * ntfs_external_attr_find - find an attribute in the attribute list of an inode
809 * @type: attribute type to find
810 * @name: attribute name to find (optional, i.e. NULL means don't care)
811 * @name_len: attribute name length (only needed if @name present)
814 * @val: attribute value to find (optional, resident attributes only)
815 * @val_len: attribute value length
816 * @ctx: search context with mft record and attribute to search from
821 * Find an attribute by searching the attribute list for the corresponding
822 * attribute list entry. Having found the entry, map the mft record if the
823 * attribute is in a different mft record/inode, ntfs_attr_find() the attribute
831 * After finishing with the attribute/mft record you need to call
835 * If the attribute is found, ntfs_external_attr_find() returns 0 and
836 * @ctx->attr will point to the found attribute. @ctx->mrec will point to the
838 * the attribute list entry for the attribute.
840 * If the attribute is not found, ntfs_external_attr_find() returns -ENOENT and
841 * @ctx->attr will point to the attribute in the base mft record before which
842 * the attribute being searched for would need to be inserted if such an action
844 * @ctx->attr is located and @ctx->al_entry will point to the attribute list
845 * entry of the attribute before which the attribute being searched for would
848 * Thus to insert the not found attribute, one wants to add the attribute to
850 * attribute should be placed in a newly allocated extent mft record. The
851 * attribute list entry for the inserted attribute should be inserted in the
852 * attribute list attribute at @ctx->al_entry.
890 * Iterate over entries in attribute list starting at @ctx->al_entry, ntfs_external_attr_find()
905 /* Catch the end of the attribute list. */ ntfs_external_attr_find()
921 * missing, assume we want an unnamed attribute. ntfs_external_attr_find()
937 * matching attribute. ntfs_external_attr_find()
961 * The names match or @name not present and attribute is ntfs_external_attr_find()
963 * next attribute list entry still fits @lowest_vcn. Otherwise ntfs_external_attr_find()
984 "reference in attribute list " ntfs_external_attr_find()
1026 * mft record containing the attribute represented by the ntfs_external_attr_find()
1031 * attribute in this mft record but this would be less ntfs_external_attr_find()
1033 * the attribute instance numbers for example which become ntfs_external_attr_find()
1034 * important when one plays with attribute lists. Also, ntfs_external_attr_find()
1035 * because a proper match has been found in the attribute list ntfs_external_attr_find()
1056 * attribute list entry and the attribute record, there is ntfs_external_attr_find()
1080 /* Proceed to the next attribute in the current mft record. */ ntfs_external_attr_find()
1086 "attribute list attribute.%s", base_ni->mft_no, ntfs_external_attr_find()
1111 * The attribute was not found. Before we return, we want to ensure ntfs_external_attr_find()
1113 * attribute should be inserted in the base mft record. Since we also ntfs_external_attr_find()
1135 * keep enumerating until we get an attribute not found response (or ntfs_external_attr_find()
1136 * another error), otherwise we would keep returning the same attribute ntfs_external_attr_find()
1149 * ntfs_attr_lookup - find an attribute in an ntfs inode
1150 * @type: attribute type to find
1151 * @name: attribute name to find (optional, i.e. NULL means don't care)
1152 * @name_len: attribute name length (only needed if @name present)
1155 * @val: attribute value to find (optional, resident attributes only)
1156 * @val_len: attribute value length
1157 * @ctx: search context with mft record and attribute to search from
1159 * Find an attribute in an ntfs inode. On first search @ctx->ntfs_ino must
1163 * This function transparently handles attribute lists and @ctx is used to
1166 * After finishing with the attribute/mft record you need to call
1172 * When 0, @ctx->attr is the found attribute and it is in mft record
1173 * @ctx->mrec. If an attribute list attribute is present, @ctx->al_entry is
1174 * the attribute list entry of the found attribute.
1176 * When -ENOENT, @ctx->attr is the attribute which collates just after the
1177 * attribute being searched for, i.e. if one wants to add the attribute to the
1178 * mft record this is the correct place to insert it into. If an attribute
1179 * list attribute is present, @ctx->al_entry is the attribute list entry which
1180 * collates just after the attribute list entry of the attribute being searched
1181 * for, i.e. if one wants to add the attribute to the mft record this is the
1182 * correct place to insert its attribute list entry into.
1210 * ntfs_attr_init_search_ctx - initialize an attribute search context
1211 * @ctx: attribute search context to initialize
1215 * Initialize the attribute search context @ctx with @ni and @mrec.
1231 * ntfs_attr_reinit_search_ctx - reinitialize an attribute search context
1232 * @ctx: attribute search context to reinitialize
1234 * Reinitialize the attribute search context @ctx, unmapping an associated
1237 * This is used when a search for a new attribute is being started to reset
1243 /* No attribute list. */ ntfs_attr_reinit_search_ctx()
1262 * ntfs_attr_get_search_ctx - allocate/initialize a new attribute search context
1266 * Allocate a new attribute search context, initialize it with @ni and @mrec,
1280 * ntfs_attr_put_search_ctx - release an attribute search context
1281 * @ctx: attribute search context to free
1283 * Release the attribute search context @ctx, unmapping an associated extent
1297 * ntfs_attr_find_in_attrdef - find an attribute in the $AttrDef system file
1298 * @vol: ntfs volume to which the attribute belongs
1299 * @type: attribute type which to find
1301 * Search for the attribute definition record corresponding to the attribute
1304 * Return the attribute type definition record if found and NULL if not found.
1318 /* We found the attribute; return it. */ ntfs_attr_find_in_attrdef()
1331 * ntfs_attr_size_bounds_check - check a size of an attribute type for validity
1332 * @vol: ntfs volume to which the attribute belongs
1333 * @type: attribute type which to check
1336 * Check whether the @size in bytes is valid for an attribute of @type on the
1339 * Return 0 if valid, -ERANGE if not valid, or -ENOENT if the attribute is not
1354 /* Get the $AttrDef entry for the attribute @type. */ ntfs_attr_size_bounds_check()
1368 * ntfs_attr_can_be_non_resident - check if an attribute can be non-resident
1369 * @vol: ntfs volume to which the attribute belongs
1370 * @type: attribute type which to check
1372 * Check whether the attribute of @type on the ntfs volume @vol is allowed to
1375 * Return 0 if the attribute is allowed to be non-resident, -EPERM if not, and
1376 * -ENOENT if the attribute is not listed in $AttrDef.
1382 /* Find the attribute definition record in $AttrDef. */ ntfs_attr_can_be_non_resident()
1393 * ntfs_attr_can_be_resident - check if an attribute can be resident
1394 * @vol: ntfs volume to which the attribute belongs
1395 * @type: attribute type which to check
1397 * Check whether the attribute of @type on the ntfs volume @vol is allowed to
1403 * Return 0 if the attribute is allowed to be non-resident and -EPERM if not.
1405 * Warning: In the system file $MFT the attribute $Bitmap must be non-resident
1418 * ntfs_attr_record_resize - resize an attribute record
1419 * @m: mft record containing attribute record
1420 * @a: attribute record to resize
1421 * @new_size: new size in bytes to which to resize the attribute record @a
1423 * Resize the attribute record @a, i.e. the resident part of the attribute, in
1441 /* If the actual attribute length has changed, move things around. */ ntfs_attr_record_resize()
1462 * ntfs_resident_attr_value_resize - resize the value of a resident attribute
1463 * @m: mft record containing attribute record
1464 * @a: attribute record whose value to resize
1465 * @new_size: new size in bytes to which to resize the attribute value of @a
1467 * Resize the value of the attribute @a in the mft record @m to @new_size bytes.
1484 /* Resize the resident part of the attribute record. */ ntfs_resident_attr_value_resize()
1489 * The resize succeeded! If we made the attribute value bigger, clear ntfs_resident_attr_value_resize()
1496 /* Finally update the length of the attribute value. */ ntfs_resident_attr_value_resize()
1502 * ntfs_attr_make_non_resident - convert a resident to a non-resident attribute
1503 * @ni: ntfs inode describing the attribute to convert
1504 * @data_size: size of the resident data to copy to the non-resident attribute
1506 * Convert the resident ntfs attribute described by the ntfs inode @ni to a
1509 * @data_size must be equal to the attribute value size. This is needed since
1517 * -EPERM - The attribute is not allowed to be non-resident.
1527 * again in case the attribute may then fit in a resident state so no need to
1530 * NOTE to self: No changes in the attribute list are required to move from
1531 * a resident to a non-resident attribute.
1552 /* Check that the attribute is allowed to be non-resident. */ ntfs_attr_make_non_resident()
1584 /* Start by allocating clusters to hold the attribute value. */ ntfs_attr_make_non_resident()
1649 * attribute record. ntfs_attr_make_non_resident()
1654 * attribute value. ntfs_attr_make_non_resident()
1668 /* Backup the attribute flag. */ ntfs_attr_make_non_resident()
1670 /* Resize the resident part of the attribute record. */ ntfs_attr_make_non_resident()
1675 * Convert the resident part of the attribute record to describe a ntfs_attr_make_non_resident()
1676 * non-resident attribute. ntfs_attr_make_non_resident()
1679 /* Move the attribute name if it exists and update the offset. */ ntfs_attr_make_non_resident()
1703 /* Generate the mapping pairs array into the attribute record. */ ntfs_attr_make_non_resident()
1711 /* Setup the in-memory attribute structure to be non-resident. */ ntfs_attr_make_non_resident()
1756 /* Convert the attribute back into a resident attribute. */ ntfs_attr_make_non_resident()
1758 /* Move the attribute name if it exists and update the offset. */ ntfs_attr_make_non_resident()
1767 /* Resize the resident part of the attribute record. */ ntfs_attr_make_non_resident()
1773 * If the old size is too small, truncate the attribute, ntfs_attr_make_non_resident()
1783 "to non-resident attribute " ntfs_attr_make_non_resident()
1785 "attribute type 0x%x from %i bytes to " ntfs_attr_make_non_resident()
1806 /* Copy the data from the page back to the attribute value. */ ntfs_attr_make_non_resident()
1846 * ntfs_attr_extend_allocation - extend the allocated space of an attribute
1847 * @ni: ntfs inode of the attribute whose allocation to extend
1852 * Extend the allocated space of an attribute described by the ntfs inode @ni
1861 * of the attribute is extended to @new_data_size. Note that the i_size of the
1862 * vfs inode is not updated. Only the data size in the base attribute record
1867 * For resident attributes this involves resizing the attribute record and if
1869 * converting the attribute to a non-resident attribute which in turn involves
1870 * extending the allocation of a non-resident attribute as described below.
1875 * updating the mapping pairs array of the attribute. This in turn involves
1876 * resizing the attribute record and if necessary moving it and/or other
1877 * attributes into extent mft records and/or splitting the attribute record
1878 * into multiple extent attribute records.
1880 * Also, the attribute list attribute is updated if present and in some of the
1882 * an attribute list attribute is created if not already present.
1896 * attribute can be resized safely and so that it can for example be converted
1899 * TODO: At present attribute list attribute handling is not implemented.
1902 * than the $DATA attribute(s) of an uncompressed and unencrypted file.
1925 ntfs_debug("Entering for i_ino 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
1957 "of inode 0x%lx, attribute " ntfs_attr_extend_allocation()
1961 "this attribute type.", ntfs_attr_extend_allocation()
1966 "of inode 0x%lx, attribute " ntfs_attr_extend_allocation()
1968 "attribute type is not " ntfs_attr_extend_allocation()
2015 * just converted the attribute from resident to non-resident it is ntfs_attr_extend_allocation()
2025 * We want the first attribute extent so that we can update the ntfs_attr_extend_allocation()
2043 /* The total length of the attribute value. */ ntfs_attr_extend_allocation()
2046 * Extend the attribute record to be able to store the new attribute ntfs_attr_extend_allocation()
2078 * Not enough space in the mft record, try to make the attribute ntfs_attr_extend_allocation()
2086 * permitted for this attribute type or there not being enough space, ntfs_attr_extend_allocation()
2096 "inode 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
2098 "to non-resident attribute failed " ntfs_attr_extend_allocation()
2113 "attribute value. This case is not " ntfs_attr_extend_allocation()
2116 ntfs_error(vol->sb, "This attribute type may not be " ntfs_attr_extend_allocation()
2127 * Both the attribute list attribute and the standard information ntfs_attr_extend_allocation()
2128 * attribute must remain in the base inode. Thus, if this is one of ntfs_attr_extend_allocation()
2141 // TODO: Attempt to move this attribute to an extent mft record, but ntfs_attr_extend_allocation()
2142 // only if it is not already the only attribute in an mft record in ntfs_attr_extend_allocation()
2158 * $DATA attribute and sparse attributes are enabled on the volume and ntfs_attr_extend_allocation()
2178 /* If this attribute extent is not mapped, map it now. */ ntfs_attr_extend_allocation()
2189 "of inode 0x%lx, attribute " ntfs_attr_extend_allocation()
2209 * there are no valid LCNs in the attribute we let the cluster ntfs_attr_extend_allocation()
2227 "inode 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
2240 "inode 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
2259 /* Find the runlist element with which the attribute extent starts. */ ntfs_attr_extend_allocation()
2272 "inode 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
2280 /* Extend the attribute record to fit the bigger mapping pairs array. */ ntfs_attr_extend_allocation()
2294 "record for the extended attribute " ntfs_attr_extend_allocation()
2308 "inode 0x%lx, attribute type 0x%x, " ntfs_attr_extend_allocation()
2319 * We now have extended the allocated size of the attribute. Reflect ntfs_attr_extend_allocation()
2320 * this in the ntfs_inode structure and the attribute record. ntfs_attr_extend_allocation()
2324 * We are not in the first attribute extent, switch to it, but ntfs_attr_extend_allocation()
2346 * regular files, and only for their $DATA attribute(s). ntfs_attr_extend_allocation()
2378 "of inode 0x%lx, attribute type 0x%x, because " ntfs_attr_extend_allocation()
2379 "lookup of first attribute extent failed with " ntfs_attr_extend_allocation()
2388 ntfs_error(vol->sb, "Failed to find last attribute extent of " ntfs_attr_extend_allocation()
2389 "attribute in error code path. Run chkdsk to " ntfs_attr_extend_allocation()
2410 * base attribute extent which chkdsk should be able to fix. ntfs_attr_extend_allocation()
2429 * longer valid, we cannot resize the attribute record or build the ntfs_attr_extend_allocation()
2436 "restore attribute search context" : ntfs_attr_extend_allocation()
2437 "truncate attribute runlist"); ntfs_attr_extend_allocation()
2441 ntfs_error(vol->sb, "Failed to restore attribute " ntfs_attr_extend_allocation()
2474 * ntfs_attr_set - fill (a part of) an attribute with a byte
2475 * @ni: ntfs inode describing the attribute to fill
2476 * @ofs: offset inside the attribute at which to start to fill
2478 * @val: the unsigned 8-bit value with which to fill the attribute
2480 * Fill @cnt bytes of the attribute described by the ntfs inode @ni starting at
2481 * byte offset @ofs inside the attribute with the constant byte @val.
2483 * This function is effectively like memset() applied to an ntfs attribute.
2485 * to the ntfs attribute and it marks them dirty after doing the memset().
2490 * that @ofs + @cnt were outside the end of the attribute and no write was
2523 ntfs_error(vol->sb, "Request exceeds end of attribute."); ntfs_attr_set()
H A Dinode.c47 * @na: ntfs attribute which is being tested with
49 * Compare the ntfs attribute embedded in the ntfs specific part of the vfs
50 * inode @vi for equality with the ntfs attribute @na.
73 /* A fake inode describing an attribute. */ ntfs_test_inode()
89 * @na: ntfs attribute which to initialize @vi to
91 * Initialize the vfs inode @vi with the values from the ntfs attribute @na in
205 * ntfs_attr_iget - obtain a struct inode corresponding to an attribute
206 * @base_vi: vfs base inode containing the attribute
207 * @type: attribute type
208 * @name: Unicode name of the attribute (NULL if unnamed)
211 * Obtain the (fake) struct inode corresponding to the attribute specified by
215 * If the attribute inode is in the cache, it is just returned with an
218 * attribute and fill in the inode structure.
223 * Return the struct inode of the attribute inode on success. Check the return
255 * There is no point in keeping bad attribute inodes around. This also ntfs_attr_iget()
256 * simplifies things in that we never need to check for bad attribute ntfs_attr_iget()
376 * The attribute runlist lock has separate locking rules from the
446 * @ctx: initialized attribute search context
448 * Search all file name attributes in the inode described by the attribute
484 "attribute. You should run chkdsk."); ntfs_is_extended_system_file()
508 /* This attribute is ok, but is it in the $Extend directory? */ ntfs_is_extended_system_file()
643 * Find the standard information attribute in the mft record. At this ntfs_read_locked_inode()
644 * stage we haven't setup the attribute list stuff yet, so this could ntfs_read_locked_inode()
655 * attribute. ntfs_read_locked_inode()
657 ntfs_error(vi->i_sb, "$STANDARD_INFORMATION attribute " ntfs_read_locked_inode()
663 /* Get the standard information attribute value. */ ntfs_read_locked_inode()
690 /* Find the attribute list attribute if present. */ ntfs_read_locked_inode()
695 ntfs_error(vi->i_sb, "Failed to lookup attribute list " ntfs_read_locked_inode()
696 "attribute."); ntfs_read_locked_inode()
706 ntfs_error(vi->i_sb, "Attribute list attribute is " ntfs_read_locked_inode()
713 ntfs_error(vi->i_sb, "Non-resident attribute " ntfs_read_locked_inode()
714 "list attribute is encrypted/" ntfs_read_locked_inode()
718 ntfs_warning(vi->i_sb, "Resident attribute list " ntfs_read_locked_inode()
719 "attribute in inode 0x%lx is marked " ntfs_read_locked_inode()
727 /* Now allocate memory for the attribute list. */ ntfs_read_locked_inode()
732 "buffer for attribute list."); ntfs_read_locked_inode()
756 /* Now load the attribute list. */ ntfs_read_locked_inode()
762 "attribute list attribute."); ntfs_read_locked_inode()
770 ntfs_error(vi->i_sb, "Corrupt attribute list " ntfs_read_locked_inode()
774 /* Now copy the attribute list. */ ntfs_read_locked_inode()
783 * If an attribute list is present we now have the attribute list value ntfs_read_locked_inode()
792 /* It is a directory, find index root attribute. */ ntfs_read_locked_inode()
799 // index root attribute if recovery option is ntfs_read_locked_inode()
801 ntfs_error(vi->i_sb, "$INDEX_ROOT attribute " ntfs_read_locked_inode()
809 ntfs_error(vol->sb, "$INDEX_ROOT attribute is not " ntfs_read_locked_inode()
813 /* Ensure the attribute name is placed before the value. */ ntfs_read_locked_inode()
816 ntfs_error(vol->sb, "$INDEX_ROOT attribute name is " ntfs_read_locked_inode()
817 "placed after the attribute value."); ntfs_read_locked_inode()
831 "compressed attribute."); ntfs_read_locked_inode()
842 ntfs_error(vi->i_sb, "$INDEX_ROOT attribute is " ntfs_read_locked_inode()
853 ntfs_error(vi->i_sb, "Indexed attribute is not " ntfs_read_locked_inode()
900 /* Setup the index allocation attribute, even if not present. */ ntfs_read_locked_inode()
918 /* Find index allocation attribute. */ ntfs_read_locked_inode()
925 "attribute is not present but " ntfs_read_locked_inode()
930 "attribute."); ntfs_read_locked_inode()
935 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute " ntfs_read_locked_inode()
940 * Ensure the attribute name is placed before the mapping pairs ntfs_read_locked_inode()
946 ntfs_error(vol->sb, "$INDEX_ALLOCATION attribute name " ntfs_read_locked_inode()
952 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute " ntfs_read_locked_inode()
957 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute " ntfs_read_locked_inode()
962 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute " ntfs_read_locked_inode()
968 "$INDEX_ALLOCATION attribute has non " ntfs_read_locked_inode()
985 /* Get the index bitmap attribute inode. */ ntfs_read_locked_inode()
988 ntfs_error(vi->i_sb, "Failed to get bitmap attribute."); ntfs_read_locked_inode()
995 ntfs_error(vi->i_sb, "$BITMAP attribute is compressed " ntfs_read_locked_inode()
1008 /* No longer need the bitmap attribute inode. */ ntfs_read_locked_inode()
1019 /* Setup the data attribute, even if not present. */ ntfs_read_locked_inode()
1024 /* Find first extent of the unnamed data attribute. */ ntfs_read_locked_inode()
1031 "attribute."); ntfs_read_locked_inode()
1036 * attribute, so we special case it here. ntfs_read_locked_inode()
1052 // attribute if recovery option is set. ntfs_read_locked_inode()
1053 ntfs_error(vi->i_sb, "$DATA attribute is missing."); ntfs_read_locked_inode()
1131 "attribute has non zero " ntfs_read_locked_inode()
1141 } else { /* Resident attribute. */ ntfs_read_locked_inode()
1148 ntfs_error(vi->i_sb, "Resident data attribute " ntfs_read_locked_inode()
1205 * ntfs_read_locked_attr_inode - read an attribute inode from its base inode
1207 * @vi: attribute inode to read
1210 * attribute inode described by @vi into memory from the base mft record
1214 * reading and looks up the attribute described by @vi before setting up the
1265 /* Find the attribute. */ ntfs_read_locked_attr_inode()
1278 "attribute. Please report " ntfs_read_locked_attr_inode()
1286 "attribute but compression is " ntfs_read_locked_attr_inode()
1304 ntfs_error(vi->i_sb, "Found mst protected attribute " ntfs_read_locked_attr_inode()
1305 "but the attribute is %s. Please " ntfs_read_locked_attr_inode()
1326 ntfs_error(vi->i_sb, "Found mst protected attribute " ntfs_read_locked_attr_inode()
1327 "but the attribute is encrypted. " ntfs_read_locked_attr_inode()
1335 "attribute."); ntfs_read_locked_attr_inode()
1341 /* Ensure the attribute name is placed before the value. */ ntfs_read_locked_attr_inode()
1345 "the attribute value."); ntfs_read_locked_attr_inode()
1349 ntfs_error(vi->i_sb, "Found mst protected attribute " ntfs_read_locked_attr_inode()
1350 "but the attribute is resident. " ntfs_read_locked_attr_inode()
1360 ntfs_error(vi->i_sb, "Resident attribute is corrupt " ntfs_read_locked_attr_inode()
1367 * Ensure the attribute name is placed before the mapping pairs ntfs_read_locked_attr_inode()
1408 ntfs_error(vi->i_sb, "First extent of attribute has " ntfs_read_locked_attr_inode()
1429 * attribute inode. ntfs_read_locked_attr_inode()
1448 ntfs_error(vol->sb, "Failed with error code %i while reading attribute " ntfs_read_locked_attr_inode()
1473 * Note, index inodes are essentially attribute inodes (NInoAttr() is true)
1474 * with the attribute type set to AT_INDEX_ALLOCATION. Apart from that, they
1477 * for small indices the index allocation attribute might not actually exist.
1478 * However, the index root attribute always exists but this does not need to
1480 * index. Also, like for directories, we need to have an attribute inode for
1481 * the bitmap attribute corresponding to the index allocation attribute and we
1531 /* Find the index root attribute. */ ntfs_read_locked_index_inode()
1536 ntfs_error(vi->i_sb, "$INDEX_ROOT attribute is " ntfs_read_locked_index_inode()
1543 ntfs_error(vol->sb, "$INDEX_ROOT attribute is not resident."); ntfs_read_locked_index_inode()
1546 /* Ensure the attribute name is placed before the value. */ ntfs_read_locked_index_inode()
1549 ntfs_error(vol->sb, "$INDEX_ROOT attribute name is placed " ntfs_read_locked_index_inode()
1550 "after the attribute value."); ntfs_read_locked_index_inode()
1560 "root attribute."); ntfs_read_locked_index_inode()
1566 ntfs_error(vi->i_sb, "$INDEX_ROOT attribute is corrupt."); ntfs_read_locked_index_inode()
1611 /* Check for presence of index allocation attribute. */ ntfs_read_locked_index_inode()
1623 /* Find index allocation attribute. */ ntfs_read_locked_index_inode()
1629 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute is " ntfs_read_locked_index_inode()
1634 "$INDEX_ALLOCATION attribute."); ntfs_read_locked_index_inode()
1639 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute is " ntfs_read_locked_index_inode()
1644 * Ensure the attribute name is placed before the mapping pairs array. ntfs_read_locked_index_inode()
1649 ntfs_error(vol->sb, "$INDEX_ALLOCATION attribute name is " ntfs_read_locked_index_inode()
1654 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute is " ntfs_read_locked_index_inode()
1659 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute is sparse."); ntfs_read_locked_index_inode()
1663 ntfs_error(vi->i_sb, "$INDEX_ALLOCATION attribute is " ntfs_read_locked_index_inode()
1669 "attribute has non zero lowest_vcn."); ntfs_read_locked_index_inode()
1684 /* Get the index bitmap attribute inode. */ ntfs_read_locked_index_inode()
1687 ntfs_error(vi->i_sb, "Failed to get bitmap attribute."); ntfs_read_locked_index_inode()
1694 ntfs_error(vi->i_sb, "$BITMAP attribute is compressed and/or " ntfs_read_locked_index_inode()
1764 * attribute list is actually present in $MFT inode.
1766 * We solve these problems by starting with the $DATA attribute before anything
1796 /* Setup the data attribute. It is special as it is mst protected. */ ntfs_read_inode_mount()
1828 /* Determine the first block of the $MFT/$DATA attribute. */ ntfs_read_inode_mount()
1854 /* Need this to sanity check attribute list references to $MFT. */ ntfs_read_inode_mount()
1866 /* Find the attribute list attribute if present. */ ntfs_read_inode_mount()
1870 ntfs_error(sb, "Failed to lookup attribute list " ntfs_read_inode_mount()
1871 "attribute. You should run chkdsk."); ntfs_read_inode_mount()
1880 ntfs_debug("Attribute list attribute found in $MFT."); ntfs_read_inode_mount()
1884 ntfs_error(sb, "Attribute list attribute is " ntfs_read_inode_mount()
1891 ntfs_error(sb, "Non-resident attribute list " ntfs_read_inode_mount()
1892 "attribute is encrypted/" ntfs_read_inode_mount()
1896 ntfs_warning(sb, "Resident attribute list attribute " ntfs_read_inode_mount()
1904 /* Now allocate memory for the attribute list. */ ntfs_read_inode_mount()
1909 "for attribute list."); ntfs_read_inode_mount()
1931 /* Now load the attribute list. */ ntfs_read_inode_mount()
1936 ntfs_error(sb, "Failed to load attribute list " ntfs_read_inode_mount()
1937 "attribute with error code %i.", ntfs_read_inode_mount()
1947 ntfs_error(sb, "Corrupt attribute list " ntfs_read_inode_mount()
1948 "attribute."); ntfs_read_inode_mount()
1951 /* Now copy the attribute list. */ ntfs_read_inode_mount()
1957 /* The attribute list is now setup in memory. */ ntfs_read_inode_mount()
1976 /* Catch the end of the attribute list. */ ntfs_read_inode_mount()
1990 /* We want an unnamed attribute. */ ntfs_read_inode_mount()
2019 /* Now load all attribute extents. */ ntfs_read_inode_mount()
2026 /* Cache the current attribute. */ ntfs_read_inode_mount()
2065 "attribute has non zero " ntfs_read_inode_mount()
2070 /* Get the last vcn in the $DATA attribute. */ ntfs_read_inode_mount()
2148 ntfs_error(sb, "$MFT has corrupt attribute list " ntfs_read_inode_mount()
2149 "attribute. Run chkdsk."); ntfs_read_inode_mount()
2154 ntfs_error(sb, "Failed to lookup $MFT/$DATA attribute extent. " ntfs_read_inode_mount()
2159 ntfs_error(sb, "$MFT/$DATA attribute not found. $MFT is " ntfs_read_inode_mount()
2186 ntfs_error(sb, "Couldn't find first extent of $DATA attribute in " ntfs_read_inode_mount()
2187 "attribute list. $MFT is corrupt. Run chkdsk."); ntfs_read_inode_mount()
2357 * or attribute inode as well as that @vi is a base inode.
2385 * safe to mess with the attribute runlist and sizes. ntfs_truncate()
2413 ntfs_error(vi->i_sb, "Open attribute is missing from " ntfs_truncate()
2418 ntfs_error(vi->i_sb, "Failed to lookup attribute in " ntfs_truncate()
2426 * The i_size of the vfs inode is the new size for the attribute value. ntfs_truncate()
2429 /* The current size of the attribute value is the old size. */ ntfs_truncate()
2471 "for its attribute type " ntfs_truncate()
2480 "attribute type 0x%x. " ntfs_truncate()
2502 /* Resize the attribute record to best fit the new attribute size. */ ntfs_truncate()
2514 * necessary data clearing in the attribute record. When the ntfs_truncate()
2544 /* If the above resize failed, this must be an attribute extension. */ ntfs_truncate()
2559 * Not enough space in the mft record, try to make the attribute ntfs_truncate()
2567 * permitted for this attribute type or there not being enough space, ntfs_truncate()
2571 ntfs_error(vol->sb, "Cannot truncate inode 0x%lx, attribute " ntfs_truncate()
2573 "resident to non-resident attribute failed " ntfs_truncate()
2583 "disk for the non-resident attribute value. " ntfs_truncate()
2586 ntfs_error(vol->sb, "This attribute type may not be " ntfs_truncate()
2596 * Both the attribute list attribute and the standard information ntfs_truncate()
2597 * attribute must remain in the base inode. Thus, if this is one of ntfs_truncate()
2610 // TODO: Attempt to move this attribute to an extent mft record, but ntfs_truncate()
2611 // only if it is not already the only attribute in an mft record in ntfs_truncate()
2627 * This attribute has multiple extents. Not yet ntfs_truncate()
2631 "attribute type 0x%x, because the " ntfs_truncate()
2632 "attribute is highly fragmented (it " ntfs_truncate()
2684 * attribute truncate case. To do this, we simply drop ntfs_truncate()
2720 * longer valid, we cannot resize the attribute record or build the ntfs_truncate()
2727 "restore attribute search context" : ntfs_truncate()
2728 "truncate attribute runlist", ntfs_truncate()
2737 "attribute type 0x%x, because determining the " ntfs_truncate()
2745 * Shrink the attribute record for the new mapping pairs array. Note, ntfs_truncate()
2746 * this cannot fail since we are making the attribute smaller thus by ntfs_truncate()
2754 * Generate the mapping pairs array directly into the attribute record. ntfs_truncate()
2761 "attribute type 0x%x, because building the " ntfs_truncate()
2877 * ntfs_setattr - called from notify_change() when an attribute is being changed
2979 * Dirty attribute inodes are written via their real inodes so just __ntfs_write_inode()
2994 /* Update the access times in the standard information attribute. */ __ntfs_write_inode()
3037 * If we just modified the standard information attribute we need to __ntfs_write_inode()
H A Dinode.h49 s64 initialized_size; /* Copy from the attribute record. */
50 s64 allocated_size; /* Copy from the attribute record. */
58 * If NInoAttr() is true, the below fields describe the attribute which
59 * this fake inode belongs to. The actual inode of this attribute is
70 the runlist of the unnamed data attribute
72 attribute (directory) or of the attribute
76 NI_NonResident is clear, the attribute is
78 no $I30 index allocation attribute
94 * Attribute list support (only for use by the attribute lookup
95 * functions). Setup during read_inode for all inodes with attribute
99 u32 attr_list_size; /* Length of attribute list value in bytes. */
101 runlist attr_list_rl; /* Run list for the attribute list value. */
112 struct { /* It is a compressed/sparse file/attribute inode. */
125 inodes describing an attribute this is -1. */
136 the attribute belongs. */
146 NI_AttrList, /* 1: Mft record contains an attribute list. */
150 NI_Attr, /* 1: Fake inode for attribute i/o.
251 * ntfs_attr - ntfs in memory attribute structure
252 * @mft_no: mft record number of the base mft record of this attribute
253 * @name: Unicode name of the attribute (NULL if unnamed)
255 * @type: attribute type (see layout.h)
H A Dusnjrnl.h50 * $VOLUME_INFORMATION attribute in the $Volume system file (which is present
56 * The transaction log consists of two parts; the $DATA/$Max attribute as well
57 * as the $DATA/$J attribute. $Max is a header describing the transaction
64 * lowest_valid_usn field in the $DATA/$Max attribute to the usn to be used
65 * for the next added USN_RECORD to the $DATA/$J attribute as well as
74 * to its usn (which is the byte offset in the $DATA/$J attribute). The
75 * second is simply to take the data size of the attribute. Since the usns
82 * $STANDARD_INFORMATION attribute to zero. Once that is done, one would need
97 * $DATA/$Max attribute. This is (always?) resident and has a fixed size of
103 attribute. */
105 size of the $DATA/$J attribute. */
159 * $DATA/$J attribute. This is always non-resident, is marked as sparse, and
164 * allocated and appended to the $DATA/$J attribute and an equal number of
165 * bytes at the beginning of the attribute are freed and made sparse. Note the
183 within the $DATA/$J attribute. */
H A Dindex.h42 * @actx: attribute search context if @is_in_root and NULL otherwise
53 * If @is_in_root is 'true', @entry is in the index root attribute @ir described
54 * by the attribute search context @actx and the base inode @base_ni. @ia and
57 * If @is_in_root is 'false', @entry is in the index allocation attribute and @ia
105 * If the index entry is in the index root attribute, simply flush the page
106 * containing the mft record containing the index root attribute.
109 * attribute, simply flush the page cache page containing the index block.
125 * If the index entry is in the index root attribute, simply mark the mft
126 * record containing the index root attribute dirty. This ensures the mft
127 * record, and hence the index root attribute, will be written out to disk
131 * attribute, mark the buffers belonging to the index record as well as the
H A Dattrib.h2 * attrib.h - Defines for attribute handling in NTFS Linux kernel driver.
35 * ntfs_attr_search_ctx - used in attribute search functions
37 * @attr: attribute record in @mrec where to begin/continue search
41 * attribute search functions. Initialize @mrec to point to the mft record to
42 * search, and @attr to point to the first attribute within @mrec (not necessary
48 * of the search attribute functions, we can call the function again, without
50 * matching attribute.
H A Dlayout.h201 * in the bitmap attribute of the mft; presumably in order to avoid accidental
207 FILE_MFT = 0, /* Master file table (mft). Data attribute
208 contains the entries and bitmap attribute
211 in data attribute. If cluster size > 4kiB,
214 FILE_LogFile = 2, /* Journalling log in data attribute. */
215 FILE_Volume = 3, /* Volume name attribute and volume information
216 attribute (flags and ntfs version). Windows
219 FILE_AttrDef = 4, /* Array of attribute definitions in data
220 attribute. */
223 data attribute. */
225 attribute. */
227 data attribute. */
228 FILE_Secure = 9, /* Shared security descriptors in data attribute
233 characters in data attribute. */
321 * This is followed by a sequence of variable length attribute records which
322 * is terminated by an attribute of type AT_END which is a truncated attribute
323 * in that it only consists of the attribute type code AT_END and none of the
324 * other members of the attribute structure are present.
350 /* 20*/ le16 attrs_offset; /* Byte offset to the first attribute in this
365 locate the attribute list attribute present
370 attribute list also means finding the other
374 the next attribute added to this mft record.
419 /* 20*/ le16 attrs_offset; /* Byte offset to the first attribute in this
434 locate the attribute list attribute present
439 attribute list also means finding the other
443 the next attribute added to this mft record.
461 * System defined attributes (32-bit). Each attribute type has a corresponding
462 * attribute name (Unicode string of maximum 64 character length) as described
463 * by the attribute definitions present in the data attribute of the $AttrDef
543 * The flags (32-bit) describing attribute properties in the attribute
547 * name attribute has this flag set and this is the only attribute indexed in
560 indexed and the attribute value must be
561 unique for the attribute type in all of
565 the attribute type in all of the mft
570 modifications to this attribute,
573 modifications if the attribute is
580 * The data attribute of FILE_AttrDef contains a sequence of attribute
584 * Entries are sorted by attribute type. The flags describe whether the
585 * attribute can be resident/non-resident and possibly other things, but the
590 /* 0*/ ntfschar name[0x40]; /* Unicode name of the attribute. Zero
592 /* 80*/ ATTR_TYPE type; /* Type of the attribute. */
596 /* 8c*/ ATTR_DEF_FLAGS flags; /* Flags describing the attribute. */
597 /* 90*/ sle64 min_size; /* Optional minimum attribute size. */
598 /* 98*/ sle64 max_size; /* Maximum size of attribute. */
619 * Only the data attribute is ever compressed in the current ntfs driver in
620 * Windows. Further, compression is only applied when the data attribute is
626 * non-resident attribute record header (more precisely: X = 2^compression_unit
675 * NOTE: At the end of the compressed attribute value, there most likely is not
689 modifying the attribute). */
699 /* 0*/ ATTR_TYPE type; /* The (32-bit) type of the attribute. */
701 attribute (aligned to 8-byte boundary).
702 Used to get to the next attribute. */
703 /* 8*/ u8 non_resident; /* If 0, attribute is resident.
704 If 1, attribute is non-resident. */
705 /* 9*/ u8 name_length; /* Unicode character size of name of attribute.
708 beginning of the name from the attribute
712 follow with attribute value or mapping pairs
716 /* 12*/ ATTR_FLAGS flags; /* Flags describing the attribute. */
717 /* 14*/ le16 instance; /* The instance of this attribute record. This
724 /* 16 */ le32 value_length;/* Byte size of attribute value. */
725 /* 20 */ le16 value_offset;/* Byte offset of the attribute
727 attribute record. When creating,
739 for this portion of the attribute value or
741 case). - Only when an attribute list is used
744 the attribute value. - Usually there is only one
745 portion, so this usually equals the attribute
766 allocated to hold the attribute value. Always
773 /* 48*/ sle64 data_size; /* Byte size of the attribute
775 attribute value is compressed or sparse. */
777 portion of the attribute value. Usually equals
780 /* 64*/ sle64 compressed_size; /* Byte size of the attribute
793 * File attribute flags (32-bit) appearing in the file_attributes fields of the
794 * STANDARD_INFORMATION attribute of MFT_RECORDs and the FILENAME_ATTR
798 * appear in the STANDARD_INFORMATION attribute whilst only some others appear
799 * in the FILENAME_ATTR attribute of MFT_RECORDs. Unless otherwise stated the
836 * attribute of an mft record.
841 an index root attribute or not. */
872 /* 8*/ sle64 last_data_change_time; /* Time the data attribute was last
897 * Recognize the difference by comparing the length of the resident attribute
903 * Upgrade attribute to NTFS 3.x format.
948 * the attribute value size.
949 * - The attribute list attribute contains one entry for each attribute of
950 * the file in which the list is located, except for the list attribute
951 * itself. The list is sorted: first by attribute type, second by attribute
953 * non-resident attribute (if present) immediately follow after the initial
959 * - The attribute list attribute value has a maximum size of 256kb. This
966 * - The mapping pairs array of some non-resident attribute becomes so
974 /* 0*/ ATTR_TYPE type; /* Type of referenced attribute. */
977 attribute or 0 if unnamed. */
978 /* 7*/ u8 name_offset; /* Byte offset to beginning of attribute name
982 of the attribute value. This is usually 0. It
983 is non-zero for the case where one attribute
986 this attribute. In the latter case, each mft
987 record holds one extent of the attribute and
988 there is one attribute list entry for each
995 attribute value. */
997 attribute being referenced; otherwise 0. */
1049 * information attribute.
1060 /* 10*/ sle64 last_data_change_time; /* Time the data attribute was last
1067 for the unnamed data attribute. So
1070 $DATA attribute and for compressed
1073 $DATA attribute. For a directory or
1075 attribute, this is always 0. NOTE:
1079 data attribute. For a directory or
1081 attribute, this is always 0. */
1153 /* The following fields are optional. The attribute value size is 16
1793 * from the standard information attribute.
1801 * FILE_Secure contains no unnamed data attribute, i.e. it has zero length. It
1809 * data attribute. The $SII index is sorted by ascending security_id.
1813 * the security descriptor's storage location within the $SDS data attribute.
1821 * descriptor in the $SDS attribute is read from the found $SDH index entry and
1822 * is stored in the $STANDARD_INFORMATION attribute of the file/directory to
1824 * attribute is present in all base mft records (i.e. in all files and
1828 * security_id and is added to the $SDS data attribute. Then, entries
1829 * referencing the this security descriptor in the $SDS data attribute are
1937 * Attribute: Data attribute (0x80).
1952 * When index header is in an index root attribute:
1955 root attribute and there is no index allocation
1956 attribute present. */
1958 attribute and/or an index allocation attribute is
1962 * allocation attribute:
1990 /* NOTE: For the index root attribute, the above two numbers are always
1991 equal, as the attribute is resident and it is resized as needed. In
1992 the case of the index allocation attribute the attribute is not
1994 equal the index_block_size specified by the INDEX_ROOT attribute
1995 corresponding to the INDEX_ALLOCATION attribute this INDEX_BLOCK
2010 * is the only attribute describing the directory. When the directory is too
2012 * are present: an index allocation attribute, containing sub-nodes of the B+
2013 * directory tree (see below), and a bitmap attribute, describing which virtual
2014 * cluster numbers (vcns) in the index allocation attribute are in use by an
2021 ATTR_TYPE type; /* Type of the indexed attribute. Is
2029 the index allocation attribute). */
2031 the index allocation attribute), when
2092 reparse point attribute. */
2132 * owner_id, is found in the standard information attribute. The collation rule
2226 * an index root attribute or an index allocation attribute.
2256 /* 16*/ union { /* The key of the indexed attribute. NOTE: Only present
2282 // of the non-resident index allocation attribute). If
2296 * When used in conjunction with the index allocation attribute, each bit
2297 * corresponds to one index block within the index allocation attribute. Thus
2299 * number of clusters in the index allocation attribute.
2361 * Attribute: Extended attribute (EA) information (0xd0).
2378 * Extended attribute flags (8-bit).
2389 * Attribute: Extended attribute (EA) (0xe0).
2393 * Like the attribute list and the index buffer list, the EA attribute value is
2423 * Operations on this attribute are logged to the journal ($LogFile) like
2427 * attribute with the name $EFS.
H A Dmft.c875 * chkdsk complains if the standard information attribute is not in the base
920 * initialized_size of the $MFT/$DATA attribute is extended and the new space
1117 * Search for a free mft record in the mft bitmap attribute on the ntfs volume
1263 * @vol: volume on which to extend the mft bitmap attribute
1265 * Extend the mft bitmap attribute on the ntfs volume @vol by one cluster.
1314 "cluster of mft bitmap attribute."); ntfs_mft_bitmap_extend_allocation_nolock()
1322 ntfs_debug("Last lcn of mft bitmap attribute is 0x%llx.", ntfs_mft_bitmap_extend_allocation_nolock()
1385 * Update the attribute record as well. Note: @rl is the last ntfs_mft_bitmap_extend_allocation_nolock()
1404 ntfs_error(vol->sb, "Failed to find last attribute extent of " ntfs_mft_bitmap_extend_allocation_nolock()
1405 "mft bitmap attribute."); ntfs_mft_bitmap_extend_allocation_nolock()
1423 "mft bitmap attribute extent."); ntfs_mft_bitmap_extend_allocation_nolock()
1429 /* Expand the attribute record if necessary. */ ntfs_mft_bitmap_extend_allocation_nolock()
1435 ntfs_error(vol->sb, "Failed to resize attribute " ntfs_mft_bitmap_extend_allocation_nolock()
1436 "record for mft bitmap attribute."); ntfs_mft_bitmap_extend_allocation_nolock()
1445 "accommodate extended mft bitmap attribute " ntfs_mft_bitmap_extend_allocation_nolock()
1457 "mft bitmap attribute."); ntfs_mft_bitmap_extend_allocation_nolock()
1464 * Reflect this in the ntfs_inode structure and the attribute record. ntfs_mft_bitmap_extend_allocation_nolock()
1468 * We are not in the first attribute extent, switch to it, but ntfs_mft_bitmap_extend_allocation_nolock()
1478 ntfs_error(vol->sb, "Failed to find first attribute " ntfs_mft_bitmap_extend_allocation_nolock()
1479 "extent of mft bitmap attribute."); ntfs_mft_bitmap_extend_allocation_nolock()
1502 ntfs_error(vol->sb, "Failed to find last attribute extent of " ntfs_mft_bitmap_extend_allocation_nolock()
1503 "mft bitmap attribute.%s", es); ntfs_mft_bitmap_extend_allocation_nolock()
1512 * base attribute extent which chkdsk should be able to fix. ntfs_mft_bitmap_extend_allocation_nolock()
1548 ntfs_error(vol->sb, "Failed to restore attribute " ntfs_mft_bitmap_extend_allocation_nolock()
1565 * @vol: volume on which to extend the mft bitmap attribute
1567 * Extend the initialized portion of the mft bitmap attribute on the ntfs
1592 /* Get the attribute record. */ ntfs_mft_bitmap_extend_initialized_nolock()
1607 ntfs_error(vol->sb, "Failed to find first attribute extent of " ntfs_mft_bitmap_extend_initialized_nolock()
1608 "mft bitmap attribute."); ntfs_mft_bitmap_extend_initialized_nolock()
1636 /* Initialize the mft bitmap attribute value with zeroes. */ ntfs_mft_bitmap_extend_initialized_nolock()
1659 ntfs_error(vol->sb, "Failed to find first attribute extent of " ntfs_mft_bitmap_extend_initialized_nolock()
1660 "mft bitmap attribute.%s", es); ntfs_mft_bitmap_extend_initialized_nolock()
1696 * ntfs_mft_data_extend_allocation_nolock - extend mft data attribute
1697 * @vol: volume on which to extend the mft data attribute
1699 * Extend the mft data attribute on the ntfs volume @vol by 16 mft records
1733 * the mft data attribute. The allocated size of the mft data ntfs_mft_data_extend_allocation_nolock()
1734 * attribute cannot be zero so we are ok to do this. ntfs_mft_data_extend_allocation_nolock()
1745 "cluster of mft data attribute."); ntfs_mft_data_extend_allocation_nolock()
1753 ntfs_debug("Last lcn of mft data attribute is 0x%llx.", (long long)lcn); ntfs_mft_data_extend_allocation_nolock()
1789 "mft data attribute.", (long long)nr); ntfs_mft_data_extend_allocation_nolock()
1806 "attribute."); ntfs_mft_data_extend_allocation_nolock()
1809 "from the mft data attribute.%s", es); ntfs_mft_data_extend_allocation_nolock()
1820 /* Update the attribute record as well. */ ntfs_mft_data_extend_allocation_nolock()
1836 ntfs_error(vol->sb, "Failed to find last attribute extent of " ntfs_mft_data_extend_allocation_nolock()
1837 "mft data attribute."); ntfs_mft_data_extend_allocation_nolock()
1855 "mft data attribute extent."); ntfs_mft_data_extend_allocation_nolock()
1861 /* Expand the attribute record if necessary. */ ntfs_mft_data_extend_allocation_nolock()
1867 ntfs_error(vol->sb, "Failed to resize attribute " ntfs_mft_data_extend_allocation_nolock()
1868 "record for mft data attribute."); ntfs_mft_data_extend_allocation_nolock()
1882 "accommodate extended mft data attribute " ntfs_mft_data_extend_allocation_nolock()
1894 "mft data attribute."); ntfs_mft_data_extend_allocation_nolock()
1901 * Reflect this in the ntfs_inode structure and the attribute record. ntfs_mft_data_extend_allocation_nolock()
1903 * attribute. ntfs_mft_data_extend_allocation_nolock()
1907 * We are not in the first attribute extent, switch to it, but ntfs_mft_data_extend_allocation_nolock()
1917 ntfs_error(vol->sb, "Failed to find first attribute " ntfs_mft_data_extend_allocation_nolock()
1918 "extent of mft data attribute."); ntfs_mft_data_extend_allocation_nolock()
1940 ntfs_error(vol->sb, "Failed to find last attribute extent of " ntfs_mft_data_extend_allocation_nolock()
1941 "mft data attribute.%s", es); ntfs_mft_data_extend_allocation_nolock()
1950 * base attribute extent which chkdsk should be able to fix. ntfs_mft_data_extend_allocation_nolock()
1960 "attribute.%s", es); ntfs_mft_data_extend_allocation_nolock()
1965 ntfs_error(vol->sb, "Failed to truncate mft data attribute " ntfs_mft_data_extend_allocation_nolock()
1980 ntfs_error(vol->sb, "Failed to restore attribute " ntfs_mft_data_extend_allocation_nolock()
1987 ntfs_error(vol->sb, "Failed to restore attribute search " ntfs_mft_data_extend_allocation_nolock()
2064 * Using attrs_offset plus eight bytes (for the termination attribute). ntfs_mft_record_layout()
2072 /* Add the termination attribute. */ ntfs_mft_record_layout()
2086 * mft record into the appropriate place of the mft data attribute. This is
2087 * used when extending the mft data attribute.
2188 * for the $DATA attribute of $MFT. This is required to avoid the possibility
2198 * allocated mft records, then we extend the $MFT/$DATA attribute in order to
2232 * for example for attribute resizing, etc, because when the run list overflows
2233 * the base mft record and an attribute list is used, it is very important that
2234 * the extension mft records used to store the $DATA attribute of $MFT can be
2381 * The mft bitmap is now uptodate. Deal with mft data attribute now. ntfs_mft_record_alloc()
2383 * modifications to the mft data attribute are complete, too, as they ntfs_mft_record_alloc()
2399 * attribute until it covers the allocated record. The loop is only ntfs_mft_record_alloc()
2431 * needed by ntfs_mft_record_format(). We will update the attribute ntfs_mft_record_alloc()
2458 /* Update the mft data attribute record to reflect the new sizes. */ ntfs_mft_record_alloc()
2475 ntfs_error(vol->sb, "Failed to find first attribute extent of " ntfs_mft_record_alloc()
2476 "mft data attribute."); ntfs_mft_record_alloc()
2505 * We can finally drop the mft bitmap lock as the mft data attribute ntfs_mft_record_alloc()
2613 * record (e.g. at a minimum a new attribute will be added to ntfs_mft_record_alloc()
2658 * Set the appropriate mode, attribute type, and name. For ntfs_mft_record_alloc()
2717 * standard information attribute yet. Also, there is no need ntfs_mft_record_alloc()
H A Dfile.c74 * ntfs_attr_extend_initialized - extend the initialized size of an attribute
75 * @ni: ntfs inode of the attribute to extend
78 * Extend the initialized size of an attribute described by the ntfs inode @ni
85 * in the resident attribute case, it is tied to the initialized size and, in
86 * the non-resident attribute case, it may not fall below the initialized size.
88 * Note that if the attribute is resident, we do not need to touch the page
131 ntfs_debug("Entering for i_ino 0x%lx, attribute type 0x%x, " ntfs_attr_extend_initialized()
166 /* The total length of the attribute value. */ ntfs_attr_extend_initialized()
170 * Do the zeroing in the mft record and update the attribute size in ntfs_attr_extend_initialized()
343 ntfs_debug("Entering for i_ino 0x%lx, attribute type 0x%x, pos " ntfs_prepare_file_for_write()
369 /* Only unnamed $DATA attribute can be compressed. */ ntfs_prepare_file_for_write()
418 "attribute type 0x%x, because " ntfs_prepare_file_for_write()
433 "attribute type 0x%x, because " ntfs_prepare_file_for_write()
444 "0x%lx, attribute " ntfs_prepare_file_for_write()
455 "attribute type 0x%x, " ntfs_prepare_file_for_write()
483 "0x%lx, attribute type 0x%x, because " ntfs_prepare_file_for_write()
618 ntfs_debug("Entering for inode 0x%lx, attribute type 0x%x, start page " ntfs_prepare_pages_for_non_resident_write()
924 "attribute type 0x%x, vcn 0x%llx, " ntfs_prepare_pages_for_non_resident_write()
1023 /* Map and lock the mft record and get the attribute record. */ ntfs_prepare_pages_for_non_resident_write()
1050 * Find the runlist element with which the attribute extent ntfs_prepare_pages_for_non_resident_write()
1084 * Resize the attribute record to fit the new mapping pairs ntfs_prepare_pages_for_non_resident_write()
1092 // TODO: Deal with this by using the current attribute ntfs_prepare_pages_for_non_resident_write()
1094 // array as possible. Then loop over each attribute ntfs_prepare_pages_for_non_resident_write()
1097 // enough space, try to resize the last attribute ntfs_prepare_pages_for_non_resident_write()
1098 // extent and if even that fails, add a new attribute ntfs_prepare_pages_for_non_resident_write()
1105 "record for the extended attribute " ntfs_prepare_pages_for_non_resident_write()
1113 * Generate the mapping pairs array directly into the attribute ntfs_prepare_pages_for_non_resident_write()
1121 "attribute type 0x%x, because building " ntfs_prepare_pages_for_non_resident_write()
1133 * If the attribute is sparse/compressed, update the compressed ntfs_prepare_pages_for_non_resident_write()
1134 * size in the ntfs_inode structure and the attribute record. ntfs_prepare_pages_for_non_resident_write()
1138 * If we are not in the first attribute extent, switch ntfs_prepare_pages_for_non_resident_write()
1241 /* Get back to the attribute extent we modified. */ ntfs_prepare_pages_for_non_resident_write()
1246 "attribute extent of attribute in " ntfs_prepare_pages_for_non_resident_write()
1256 * size of the base attribute extent which chkdsk ntfs_prepare_pages_for_non_resident_write()
1270 * new mapping pairs array, i.e. only when the mapped attribute extent ntfs_prepare_pages_for_non_resident_write()
1278 "attribute runlist in error code " ntfs_prepare_pages_for_non_resident_write()
1301 * Resize the attribute record to its old size and rebuild the mapping ntfs_prepare_pages_for_non_resident_write()
1304 * attribute extent is not switched. ntfs_prepare_pages_for_non_resident_write()
1308 ntfs_error(vol->sb, "Failed to restore attribute " ntfs_prepare_pages_for_non_resident_write()
1329 /* Release the mft record and the attribute. */ ntfs_prepare_pages_for_non_resident_write()
1575 ntfs_debug("Entering for inode 0x%lx, attribute type 0x%x, start page " ntfs_commit_pages_after_write()
1614 /* The total length of the attribute value. */ ntfs_commit_pages_after_write()
1626 /* Update the attribute length if necessary. */ ntfs_commit_pages_after_write()
1640 /* Zero the region outside the end of the attribute value. */ ntfs_commit_pages_after_write()
1683 ntfs_error(vi->i_sb, "Resident attribute commit write failed " ntfs_commit_pages_after_write()
1759 ntfs_debug("Entering for i_ino 0x%lx, attribute type 0x%x, pos " ntfs_perform_write()
1777 "0x%lx, attribute type 0x%x, because " ntfs_perform_write()
1823 "attribute type 0x%x, " ntfs_perform_write()
1824 "because the attribute " ntfs_perform_write()
1972 * records as well as the $DATA attribute and then sync the block device.
1974 * If @datasync is true and the attribute is non-resident, we skip the writing
1983 * TODO: We should probably also write all attribute/index inodes associated
/linux-4.1.27/fs/sysfs/
H A Dsysfs.h32 const struct attribute *attr, bool is_bin);
34 const struct attribute *attr, bool is_bin,
H A Dgroup.c24 struct attribute *const *attr; remove_files()
38 struct attribute *const *attr; create_files()
131 * sysfs_create_group - given a directory kobject, create an attribute group
133 * @grp: The attribute group to create
136 * warn and error if any of the attribute files being created already exist.
148 * sysfs_create_groups - given a directory kobject, create a bunch of attribute groups
150 * @groups: The attribute groups to create, NULL terminated
152 * This function creates a bunch of attribute groups. If an error occurs when
155 * It will explicitly warn and error if any of the attribute files being
182 * sysfs_update_group - given a directory kobject, update an attribute group
184 * @grp: The attribute group to update
186 * This function updates an attribute group. Unlike
188 * of the attribute files being created already exist. Furthermore,
261 * sysfs_merge_group - merge files into a pre-existing attribute group.
263 * @grp: The files to create and the attribute group they belong to.
274 struct attribute *const *attr; sysfs_merge_group()
294 * sysfs_unmerge_group - remove files from a pre-existing attribute group.
296 * @grp: The files to remove and the attribute group they belong to.
302 struct attribute *const *attr; sysfs_unmerge_group()
314 * sysfs_add_link_to_group - add a symlink to an attribute group.
338 * sysfs_remove_link_from_group - remove a symlink from an attribute group.
H A Dfile.c239 const struct attribute *attr, bool is_bin, sysfs_add_file_mode_ns()
251 /* every kobject with an attribute needs a ktype assigned */ sysfs_add_file_mode_ns()
253 "missing sysfs attribute operations for kobject: %s\n", sysfs_add_file_mode_ns()
307 int sysfs_add_file(struct kernfs_node *parent, const struct attribute *attr, sysfs_add_file()
314 * sysfs_create_file_ns - create an attribute file for an object with custom ns
316 * @attr: attribute descriptor
319 int sysfs_create_file_ns(struct kobject *kobj, const struct attribute *attr, sysfs_create_file_ns()
329 int sysfs_create_files(struct kobject *kobj, const struct attribute **ptr) sysfs_create_files()
344 * sysfs_add_file_to_group - add an attribute file to a pre-existing group.
346 * @attr: attribute descriptor.
350 const struct attribute *attr, const char *group) sysfs_add_file_to_group()
373 * sysfs_chmod_file - update the modified mode value on an object attribute.
375 * @attr: attribute descriptor.
379 int sysfs_chmod_file(struct kobject *kobj, const struct attribute *attr, sysfs_chmod_file()
401 * sysfs_remove_file_ns - remove an object attribute with a custom ns tag
403 * @attr: attribute descriptor
406 * Hash the attribute name and namespace tag and kill the victim.
408 void sysfs_remove_file_ns(struct kobject *kobj, const struct attribute *attr, sysfs_remove_file_ns()
418 * sysfs_remove_file_self - remove an object attribute from its own method
420 * @attr: attribute descriptor
424 bool sysfs_remove_file_self(struct kobject *kobj, const struct attribute *attr) sysfs_remove_file_self()
440 void sysfs_remove_files(struct kobject *kobj, const struct attribute **ptr) sysfs_remove_files()
449 * sysfs_remove_file_from_group - remove an attribute file from a group.
451 * @attr: attribute descriptor.
455 const struct attribute *attr, const char *group) sysfs_remove_file_from_group()
476 * @attr: attribute descriptor.
490 * @attr: attribute descriptor.
/linux-4.1.27/drivers/hid/
H A Dhid-sensor-custom.c36 struct hid_sensor_hub_attribute_info attribute; member in struct:hid_sensor_custom_field
39 struct attribute *attrs[HID_CUSTOM_TOTAL_ATTRS];
70 static struct attribute hid_custom_attrs[] = {
194 sensor_inst->power_state->attribute.report_id, set_power_report_state()
195 sensor_inst->power_state->attribute.index, set_power_report_state()
199 sensor_inst->report_state->attribute.report_id, set_power_report_state()
200 sensor_inst->report_state->attribute.index, set_power_report_state()
205 sensor_inst->power_state->attribute.logical_minimum; set_power_report_state()
207 sensor_inst->power_state->attribute.report_id, set_power_report_state()
208 sensor_inst->power_state->attribute.index, set_power_report_state()
220 sensor_inst->report_state->attribute.logical_minimum; set_power_report_state()
222 sensor_inst->report_state->attribute.report_id, set_power_report_state()
223 sensor_inst->report_state->attribute.index, set_power_report_state()
274 static struct attribute *enable_sensor_attrs[] = {
288 struct hid_sensor_hub_attribute_info *attribute; show_value() local
310 attribute = &sensor_inst->fields[field_index].attribute; show_value()
311 report_id = attribute->report_id; show_value()
326 if (i + attribute->size > ret) { show_value()
332 switch (attribute->size) { show_value()
335 i += attribute->size; show_value()
339 i += attribute->size; show_value()
343 i += attribute->size; show_value()
363 value = sensor_inst->fields[field_index].attribute.units; show_value()
365 value = sensor_inst->fields[field_index].attribute.unit_expo; show_value()
367 value = sensor_inst->fields[field_index].attribute.size; show_value()
369 value = sensor_inst->fields[field_index].attribute. show_value()
372 value = sensor_inst->fields[field_index].attribute. show_value()
414 report_id = sensor_inst->fields[field_index].attribute. store_value()
499 sensor_field->attribute.usage_id = sensor_inst->hsdev->usage; hid_sensor_custom_add_field()
501 sensor_field->attribute.attrib_id = field->logical; hid_sensor_custom_add_field()
503 sensor_field->attribute.attrib_id = field->usage[0].hid; hid_sensor_custom_add_field()
505 sensor_field->attribute.index = index; hid_sensor_custom_add_field()
506 sensor_field->attribute.report_id = report->id; hid_sensor_custom_add_field()
507 sensor_field->attribute.units = field->unit; hid_sensor_custom_add_field()
508 sensor_field->attribute.unit_expo = field->unit_exponent; hid_sensor_custom_add_field()
509 sensor_field->attribute.size = (field->report_size / 8); hid_sensor_custom_add_field()
510 sensor_field->attribute.logical_minimum = field->logical_minimum; hid_sensor_custom_add_field()
511 sensor_field->attribute.logical_maximum = field->logical_maximum; hid_sensor_custom_add_field()
516 sensor_field->attribute.index, hid_sensor_custom_add_field()
517 sensor_field->attribute.attrib_id); hid_sensor_custom_add_field()
521 "input-%x-%x", sensor_field->attribute.index, hid_sensor_custom_add_field()
522 sensor_field->attribute.attrib_id); hid_sensor_custom_add_field()
623 if (sensor_inst->fields[i].attribute.attrib_id == hid_sensor_custom_add_attributes()
626 else if (sensor_inst->fields[i].attribute.attrib_id == hid_sensor_custom_add_attributes()
/linux-4.1.27/samples/kobject/
H A Dkset-example.c39 /* a custom attribute that works just for a struct foo_obj. */
41 struct attribute attr;
55 struct attribute *attr, foo_attr_show()
58 struct foo_attribute *attribute; foo_attr_show() local
61 attribute = to_foo_attr(attr); foo_attr_show()
64 if (!attribute->show) foo_attr_show()
67 return attribute->show(foo, attribute, buf); foo_attr_show()
75 struct attribute *attr, foo_attr_store()
78 struct foo_attribute *attribute; foo_attr_store() local
81 attribute = to_foo_attr(attr); foo_attr_store()
84 if (!attribute->store) foo_attr_store()
87 return attribute->store(foo, attribute, buf, len); foo_attr_store()
138 * looking at the attribute for the "baz" and "bar" files.
177 static struct attribute *foo_default_attrs[] = {
H A Dkobject-example.c54 * looking at the attribute for the "baz" and "bar" files.
94 static struct attribute *attrs[] = {
102 * An unnamed attribute group will put all of the attributes directly in
105 * attribute group.
/linux-4.1.27/include/rdma/
H A Drdma_netlink.h48 * Put a new attribute in a supplied skb.
50 * @nlh: Header of the netlink message to append the attribute to.
51 * @len: The length of the attribute data.
52 * @data: The attribute data to put.
53 * @type: The attribute type.
/linux-4.1.27/arch/powerpc/platforms/powernv/
H A Dopal-elog.c34 struct attribute attr;
94 struct attribute *attr, elog_attr_show()
97 struct elog_attribute *attribute; elog_attr_show() local
100 attribute = to_elog_attr(attr); elog_attr_show()
103 if (!attribute->show) elog_attr_show()
106 return attribute->show(elog, attribute, buf); elog_attr_show()
110 struct attribute *attr, elog_attr_store()
113 struct elog_attribute *attribute; elog_attr_store() local
116 attribute = to_elog_attr(attr); elog_attr_store()
119 if (!attribute->store) elog_attr_store()
122 return attribute->store(elog, attribute, buf, len); elog_attr_store()
139 static struct attribute *elog_default_attrs[] = {
H A Dopal-dump.c34 struct attribute attr;
101 * The binary attribute of the dump itself is dynamic
146 static struct attribute *initiate_attrs[] = {
158 struct attribute *attr, dump_attr_show()
161 struct dump_attribute *attribute; dump_attr_show() local
164 attribute = to_dump_attr(attr); dump_attr_show()
167 if (!attribute->show) dump_attr_show()
170 return attribute->show(dump, attribute, buf); dump_attr_show()
174 struct attribute *attr, dump_attr_store()
177 struct dump_attribute *attribute; dump_attr_store() local
180 attribute = to_dump_attr(attr); dump_attr_store()
183 if (!attribute->store) dump_attr_store()
186 return attribute->store(dump, attribute, buf, len); dump_attr_store()
203 static struct attribute *dump_default_attrs[] = {
/linux-4.1.27/drivers/firmware/efi/
H A Druntime-map.c29 struct attribute attr;
33 static inline struct map_attribute *to_map_attr(struct attribute *attr) to_map_attr()
54 EFI_RUNTIME_U64_ATTR_SHOW(attribute); variable
61 static ssize_t map_attr_show(struct kobject *kobj, struct attribute *attr, map_attr_show()
74 static struct map_attribute map_attribute_attr = __ATTR_RO(attribute);
79 static struct attribute *def_attrs[] = {
H A Defi.c134 static struct attribute *efi_subsys_attrs[] = {
144 struct attribute *attr, int n) efi_attr_is_visible()
209 pr_err("efi: Sysfs attribute export failed with error %d.\n", efisubsys_init()
257 if (!(md->attribute & EFI_MEMORY_RUNTIME) && efi_lookup_mapped_addr()
504 attr = md->attribute; efi_md_typeattr_format()
/linux-4.1.27/fs/ext2/
H A Dxattr.h12 /* Magic value in attribute blocks */
15 /* Maximum number of references to one attribute block */
36 __u8 e_name_index; /* attribute name index */
38 __le32 e_value_block; /* disk block attribute is stored on (n/i) */
39 __le32 e_value_size; /* size of attribute value */
41 char e_name[0]; /* attribute name */
H A Dxattr.c18 * inodes may share the same extended attribute block. Such situations
19 * are automatically detected by keeping a cache of recent attribute block
23 * Extended attribute block layout:
39 * byte boundaries. The entry descriptors are sorted by attribute name,
40 * so that two extended attribute blocks can be compared efficiently.
141 * Copy an extended attribute into the buffer
188 /* find named attribute */ ext2_xattr_get()
220 /* return value of attribute */ ext2_xattr_get()
236 * Copy a list of attribute names into the buffer
289 /* list the attribute names */ ext2_xattr_list()
348 * Create, replace or remove an extended attribute for this inode. Value
349 * is NULL to remove an existing extended attribute, and non-NULL to
350 * either replace an existing extended attribute, or create a new extended
351 * attribute. The flags XATTR_REPLACE and XATTR_CREATE
352 * specify that an extended attribute must exist and must not exist
393 /* The inode already has an extended attribute block. */ ext2_xattr_set()
411 /* Find the named attribute. */ ext2_xattr_set()
448 /* We will use a new extended attribute block. */ ext2_xattr_set()
455 /* Request to remove a nonexistent attribute? */ ext2_xattr_set()
463 /* Request to create an existing attribute? */ ext2_xattr_set()
481 /* Here we know that we can set the new attribute. */ ext2_xattr_set()
751 * Free extended attribute resources associated with this inode. This
821 * Create a new entry in the extended attribute cache, and insert
855 * Compare two extended attribute blocks for equality.
895 * Find an identical extended attribute block.
954 * Compute the hash of an extended attribute.
990 * Re-compute the extended attribute hash value after an entry has changed.
/linux-4.1.27/fs/ext3/
H A Dxattr.h11 /* Magic value in attribute blocks */
14 /* Maximum number of references to one attribute block */
39 __u8 e_name_index; /* attribute name index */
41 __le32 e_value_block; /* disk block attribute is stored on (n/i) */
42 __le32 e_value_size; /* size of attribute value */
44 char e_name[0]; /* attribute name */
H A Dxattr.c42 * attribute values are aligned to the end of the block in no specific order.
306 * Copy an extended attribute into the buffer
423 * Copy a list of attribute names into the buffer
641 /* The inode already has an extended attribute block. */ ext3_xattr_block_find()
656 /* Find the named attribute. */ ext3_xattr_block_find()
891 /* Find the named attribute. */ ext3_xattr_ibody_find()
930 * Create, replace or remove an extended attribute for this inode. Value
931 * is NULL to remove an existing extended attribute, and non-NULL to
932 * either replace an existing extended attribute, or create a new extended
933 * attribute. The flags XATTR_REPLACE and XATTR_CREATE
934 * specify that an extended attribute must exist and must not exist
1047 * attribute modification is a filesystem transaction by itself.
1081 * Free extended attribute resources associated with this inode. This
1127 * Create a new entry in the extended attribute cache, and insert
1160 * Compare two extended attribute blocks for equality.
1200 * Find an identical extended attribute block.
1253 * Compute the hash of an extended attribute.
1289 * Re-compute the extended attribute hash value after an entry has changed.
/linux-4.1.27/fs/ext4/
H A Dxattr.h11 /* Magic value in attribute blocks */
14 /* Maximum number of references to one attribute block */
44 __u8 e_name_index; /* attribute name index */
46 __le32 e_value_block; /* disk block attribute is stored on (n/i) */
47 __le32 e_value_size; /* size of attribute value */
49 char e_name[0]; /* attribute name */
H A Dxattr.c42 * attribute values are aligned to the end of the block in no specific order.
371 * Copy an extended attribute into the buffer
492 * Copy a list of attribute names into the buffer
743 /* The inode already has an extended attribute block. */ ext4_xattr_block_find()
757 /* Find the named attribute. */ ext4_xattr_block_find()
998 /* Find the named attribute. */ ext4_xattr_ibody_find()
1074 * Create, replace or remove an extended attribute for this inode. Value
1075 * is NULL to remove an existing extended attribute, and non-NULL to
1076 * either replace an existing extended attribute, or create a new extended
1077 * attribute. The flags XATTR_REPLACE and XATTR_CREATE
1078 * specify that an extended attribute must exist and must not exist
1195 * attribute modification is a filesystem transaction by itself.
1482 * Free extended attribute resources associated with this inode. This
1526 * Create a new entry in the extended attribute cache, and insert
1559 * Compare two extended attribute blocks for equality.
1599 * Find an identical extended attribute block.
1652 * Compute the hash of an extended attribute.
1688 * Re-compute the extended attribute hash value after an entry has changed.
/linux-4.1.27/fs/ubifs/
H A Dxattr.c27 * which limits extended attribute size to UBIFS block size (4KiB). Names of
28 * extended attributes are described by extended attribute entries (xentries),
34 * directory entries. Extended attribute entries store the name of the extended
35 * attribute, the host inode number, and the extended attribute inode number.
43 * the sum of all extended attribute names of the inode does not exceed that
47 * flash media synchronously and there is no write-back for extended attribute
48 * inodes. The extended attribute values are not stored in compressed form on
71 * Extended attribute type constants.
73 * USER_XATTR: user extended attribute ("user.*")
74 * TRUSTED_XATTR: trusted extended attribute ("trusted.*)
75 * SECURITY_XATTR: security extended attribute ("security.*")
87 * create_xattr - create an extended attribute.
90 * @nm: extended attribute name
91 * @value: extended attribute value
92 * @size: size of extended attribute value
94 * This is a helper function which creates an extended attribute of name @nm
96 * because the ctime and extended attribute accounting data changes. This
116 * Linux limits the maximum size of the extended attribute names list create_xattr()
186 * change_xattr - change an extended attribute.
189 * @inode: extended attribute inode
190 * @value: extended attribute value
191 * @size: size of extended attribute value
193 * This helper function changes the value of extended attribute @inode with new
228 * the extended attribute inode gets synchronized, because it goes change_xattr()
250 * check_namespace - check extended attribute name-space.
251 * @nm: extended attribute name
253 * This function makes sure the extended attribute name belongs to one of the
254 * supported extended attribute name-spaces. Returns name-space index in case
291 ubifs_err(c, "dead extended attribute entry, error %d", iget_xattr()
297 ubifs_err(c, "corrupt extended attribute entry"); iget_xattr()
326 * The extended attribute entries are stored in LNC, so multiple setxattr()
449 * null-terminated list of all the extended attribute names. ubifs_listxattr()
/linux-4.1.27/drivers/gpu/drm/amd/amdkfd/
H A Dkfd_topology.h90 struct attribute attr;
113 struct attribute attr;
131 struct attribute attr;
149 struct attribute attr_gpuid;
150 struct attribute attr_name;
151 struct attribute attr_props;
162 struct attribute attr_genid;
163 struct attribute attr_props;
/linux-4.1.27/drivers/block/drbd/
H A Ddrbd_nla.c46 * If any nested attribute has the DRBD_GENLA_F_MANDATORY flag set and drbd_nla_find_nested()
47 * we don't know about that attribute, reject all the nested drbd_nla_find_nested()
/linux-4.1.27/fs/xfs/
H A Dxfs_sysfs.c26 struct attribute attr;
32 to_attr(struct attribute *attr) to_attr()
87 static struct attribute *xfs_dbg_attrs[] = {
95 struct attribute *attr, xfs_dbg_show()
106 struct attribute *attr, xfs_dbg_store()
190 static struct attribute *xfs_log_attrs[] = {
208 struct attribute *attr, xfs_log_show()
220 struct attribute *attr, xfs_log_store()
H A Dxfs_attr.h26 * Large attribute lists are structured around Btrees where all the data
29 * of an attribute name may not be unique, we may have duplicate keys.
32 * Small attribute lists use a different format and are packed as tightly
63 * attribute value or the buffer used for an attr_list() call. Larger
69 * Define how lists of attribute names are returned to the user from
81 * Show the interesting info about one attribute. This is what the
91 * and an index, return a pointer to the indicated attribute in the buffer.
H A Dxfs_attr_inactive.c63 * Roll through the "value", invalidating the attribute value's xfs_attr3_leaf_freextent()
204 * Recurse (gasp!) through the attribute nodes until we find leaves.
320 * Indiscriminately delete the entire attribute fork
322 * Recurse (gasp!) through the attribute nodes until we find leaves.
384 * xfs_attr_inactive kills all traces of an attribute fork on an inode. It
386 * handle the condition of inodes without attributes but with an attribute fork
389 * The in-memory attribute fork is removed even on error.
439 * Invalidate and truncate the attribute fork extents. Make sure the xfs_attr_inactive()
455 /* Reset the attribute fork - this also destroys the in-core fork */ xfs_attr_inactive()
H A Dxfs_attr_list.c62 * Copy out entries of shortform attribute lists for attr_list().
63 * Shortform attribute lists are not stored in hashval sorted order.
138 * Scan the attribute list for the rest of the entries, storing xfs_attr_shortform_list()
361 * Copy out attribute list entries for attr_list(), for leaf attribute lists.
487 * Copy out attribute entries for attr_list(), for leaf attribute lists.
544 * Format an attribute and copy it out to the user's buffer.
598 * Generate a list of extended attribute names and optionally
/linux-4.1.27/drivers/hwmon/
H A Dabx500.h20 * @show_label: hwmon attribute label
21 * @is_visible: is attribute visible
30 int (*is_visible)(struct attribute *, int);
H A Ds3c-hwmon.c90 * @dev: The device that the attribute belongs to.
91 * @attr: The attribute being read.
94 * This show deals with the raw attribute, registered for each possible
119 static struct attribute *s3c_hwmon_attrs[9] = {
154 * @dev: The device that the attribute belongs to. s3c_hwmon_remove_raw()
155 * @attr: The attribute being read. s3c_hwmon_remove_raw()
186 * @dev: The device that the attribute belongs to.
187 * @attr: The attribute being read.
206 * s3c_hwmon_create_attr - create hwmon attribute for given channel.
207 * @dev: The device to create the attribute on.
211 * Create the scaled attribute for use with hwmon from the specified
215 * The attribute name is taken from the configuration data if present
238 dev_err(dev, "failed to create input attribute\n"); s3c_hwmon_create_attr()
257 dev_err(dev, "failed to create label attribute\n"); s3c_hwmon_create_attr()
H A Dvexpress.c76 struct attribute *attr, int index) vexpress_hwmon_attr_is_visible()
98 static struct attribute *vexpress_hwmon_attrs_volt[] = {
119 static struct attribute *vexpress_hwmon_attrs_amp[] = {
139 static struct attribute *vexpress_hwmon_attrs_temp[] = {
159 static struct attribute *vexpress_hwmon_attrs_power[] = {
179 static struct attribute *vexpress_hwmon_attrs_energy[] = {
H A Dhwmon.c43 static struct attribute *hwmon_dev_attrs[] = {
49 struct attribute *attr, int n) hwmon_dev_name_is_visible()
86 * @name: hwmon name attribute
88 * @groups: List of attribute groups to create
103 /* Do not accept invalid characters in hwmon name attribute */ hwmon_device_register_with_groups()
181 * @name: hwmon name attribute
183 * @groups: List of attribute groups to create
H A Dibmpowernv.c216 * This function translates the DT node name into the 'hwmon' attribute name.
303 * add a new attribute for labels for_each_child_of_node()
313 sizeof(struct attribute *) *
344 * a sysfs attribute file, the file is named by translating the DT node name
398 * hwmon attribute name for_each_child_of_node()
417 * For the label attribute, we can reuse the for_each_child_of_node()
419 * attribute. They are related to the same for_each_child_of_node()
456 /* Create sysfs attribute data for each sensor found in the DT */ ibmpowernv_probe()
H A Dmax1111.c94 * NOTE: SPI devices do not have a default 'name' attribute, which is
96 * different devices, explicitly add a name attribute here.
135 static struct attribute *max1111_attributes[] = {
148 static struct attribute *max1110_attributes[] = {
227 dev_err(&spi->dev, "failed to create attribute group\n"); max1111_probe()
234 "failed to create extended attribute group\n"); max1111_probe()
H A Dhih6130.c168 * @attr: device attribute
171 * Will be called on read access to temp1_input sysfs attribute.
190 * @attr: device attribute
193 * Will be called on read access to humidity1_input sysfs attribute.
214 static struct attribute *hih6130_attrs[] = {
H A Dsht21.c127 * @attr: device attribute
130 * Will be called on read access to temp1_input sysfs attribute.
149 * @attr: device attribute
152 * Will be called on read access to humidity1_input sysfs attribute.
174 static struct attribute *sht21_attrs[] = {
H A Demc1403.c251 static struct attribute *emc1402_attrs[] = {
276 static struct attribute *emc1403_attrs[] = {
304 static struct attribute *emc1404_attrs[] = {
325 * fault status. For simplicity, provide a separate attribute group for this
327 * Since we can not re-use the same attribute names, create a separate attribute
341 static struct attribute *emc1402_alarm_attrs[] = {
H A Dnct7904.c177 struct attribute *a, int n) nct7904_fanin_is_visible()
200 static struct attribute *nct7904_fanin_attrs[] = {
259 struct attribute *a, int n) nct7904_vsen_is_visible()
296 static struct attribute *nct7904_vsen_attrs[] = {
345 struct attribute *a, int n) nct7904_tcpu_is_visible()
365 static struct attribute *nct7904_tcpu_attrs[] = {
468 static struct attribute *nct7904_fanctl_attrs[] = {
H A Dnct6683.c311 /* Voltage attribute values */
314 /* Temperature attribute values */
320 /* Fan attribute values */
392 umode_t (*is_visible)(struct kobject *, struct attribute *, int);
405 struct attribute **attrs; nct6683_create_attr_group()
676 struct attribute *attr, int index) nct6683_in_is_visible()
680 int nr = index % 4; /* attribute */ nct6683_in_is_visible()
741 struct attribute *attr, int index) nct6683_fan_is_visible()
746 int nr = index % 3; /* attribute index */ nct6683_fan_is_visible()
859 struct attribute *attr, int index) nct6683_temp_is_visible()
864 int nr = index % 7; /* attribute index */ nct6683_temp_is_visible()
924 struct attribute *attr, int index) nct6683_pwm_is_visible()
1076 static struct attribute *nct6683_attributes_other[] = {
1129 * Temperature and voltage attribute mapping is determined by walking through
H A Dmax16065.c415 static struct attribute *max16065_basic_attributes[] = {
479 static struct attribute *max16065_current_attributes[] = {
486 static struct attribute *max16065_min_attributes[] = {
502 static struct attribute *max16065_max_attributes[] = {
519 struct attribute *a, int n) max16065_basic_is_visible()
531 struct attribute *a, int index) max16065_secondary_is_visible()
H A Ddme1737.c1265 static struct attribute *dme1737_pwm_chmod_attr[];
1266 static void dme1737_chmod_file(struct device*, struct attribute*, umode_t);
1515 * Sysfs device attribute defines and structs
1658 static struct attribute *dme1737_attr[] = {
1725 static struct attribute *dme1737_temp_offset_attr[] = {
1741 static struct attribute *dme1737_vid_attr[] = {
1756 static struct attribute *dme1737_zone3_attr[] = {
1774 static struct attribute *dme1737_zone_hyst_attr[] = {
1790 static struct attribute *dme1737_in7_attr[] = {
1807 static struct attribute *dme1737_pwm1_attr[] = {
1817 static struct attribute *dme1737_pwm2_attr[] = {
1827 static struct attribute *dme1737_pwm3_attr[] = {
1837 static struct attribute *dme1737_pwm5_attr[] = {
1843 static struct attribute *dme1737_pwm6_attr[] = {
1864 static struct attribute *dme1737_auto_pwm_min_attr[] = {
1875 static struct attribute *dme1737_fan1_attr[] = {
1882 static struct attribute *dme1737_fan2_attr[] = {
1889 static struct attribute *dme1737_fan3_attr[] = {
1896 static struct attribute *dme1737_fan4_attr[] = {
1903 static struct attribute *dme1737_fan5_attr[] = {
1910 static struct attribute *dme1737_fan6_attr[] = {
1931 static struct attribute *dme1737_zone_chmod_attr[] = {
1950 static struct attribute *dme1737_zone3_chmod_attr[] = {
1966 static struct attribute *dme1737_pwm1_chmod_attr[] = {
1974 static struct attribute *dme1737_pwm2_chmod_attr[] = {
1982 static struct attribute *dme1737_pwm3_chmod_attr[] = {
1990 static struct attribute *dme1737_pwm5_chmod_attr[] = {
1995 static struct attribute *dme1737_pwm6_chmod_attr[] = {
2014 static struct attribute *dme1737_pwm_chmod_attr[] = {
2053 struct attribute *attr, umode_t mode) dme1737_chmod_file()
2065 struct attribute **attr; dme1737_chmod_group()
2115 /* Create a name attribute for ISA devices */ dme1737_create_files()
H A Diio_hwmon.c27 * @attrs: null terminated array of attribute pointers.
35 struct attribute **attrs;
/linux-4.1.27/fs/btrfs/
H A Dsysfs.h63 /* convert from attribute */
70 static inline struct kobj_attribute *attr_to_btrfs_attr(struct attribute *attr) attr_to_btrfs_attr()
76 attr_to_btrfs_feature_attr(struct attribute *attr) attr_to_btrfs_feature_attr()
H A Dsysfs.c174 struct attribute *attr, int unused) btrfs_feature_visible()
205 static struct attribute *btrfs_supported_feature_attrs[] = {
281 static struct attribute *raid_attributes[] = {
327 static struct attribute *space_info_attrs[] = {
353 static const struct attribute *allocation_attrs[] = {
431 static struct attribute *btrfs_attrs[] = {
474 struct attribute *attrs[2]; addrm_unknown_feature_attrs()
577 struct attribute *a = btrfs_supported_feature_attrs[i]; init_feature_attrs()
/linux-4.1.27/net/batman-adv/
H A Dsysfs.h31 struct attribute attr;
32 ssize_t (*show)(struct kobject *kobj, struct attribute *attr,
34 ssize_t (*store)(struct kobject *kobj, struct attribute *attr,
H A Dsysfs.c124 struct attribute *attr, char *buff, \
136 struct attribute *attr, char *buff) \
156 struct attribute *attr, char *buff, \
169 struct attribute *attr, char *buff) \
187 struct attribute *attr, char *buff, \
203 struct attribute *attr, char *buff) \
262 struct attribute *attr, __batadv_store_bool_attr()
317 const struct attribute *attr, __batadv_store_uint_attr()
331 struct attribute *attr, char *buff) batadv_show_bat_algo()
345 static ssize_t batadv_show_gw_mode(struct kobject *kobj, struct attribute *attr, batadv_show_gw_mode()
370 struct attribute *attr, char *buff, batadv_store_gw_mode()
438 struct attribute *attr, char *buff) batadv_show_gw_bwidth()
451 struct attribute *attr, char *buff, batadv_store_gw_bwidth()
465 * @attr: the batman-adv attribute the user is interacting with
472 struct attribute *attr, char *buff) batadv_show_isolation_mark()
484 * @attr: the batman-adv attribute the user is interacting with
491 struct attribute *attr, char *buff, batadv_store_isolation_mark()
728 struct attribute *attr, char *buff) batadv_show_mesh_iface()
752 struct attribute *attr, char *buff, batadv_store_mesh_iface()
809 struct attribute *attr, char *buff) batadv_show_iface_status()
/linux-4.1.27/arch/s390/kernel/
H A Dperf_cpum_cf_events.c118 static struct attribute *cpumcf_pmu_event_attr[] = {
150 static struct attribute *cpumcf_z10_pmu_event_attr[] __initdata = {
172 static struct attribute *cpumcf_z196_pmu_event_attr[] __initdata = {
200 static struct attribute *cpumcf_zec12_pmu_event_attr[] __initdata = {
248 static struct attribute *cpumsf_pmu_format_attr[] = {
265 static __init struct attribute **merge_attr(struct attribute **a, merge_attr()
266 struct attribute **b) merge_attr()
268 struct attribute **new; merge_attr()
277 new = kmalloc(sizeof(struct attribute *) * j, GFP_KERNEL); merge_attr()
292 struct attribute **combined, **model; cpumf_cf_event_group()
/linux-4.1.27/drivers/net/ethernet/intel/fm10k/
H A Dfm10k_tlv.c45 * @string: Pointer to string to be stored in attribute
48 * the attribute buffer. It will return success if provided with a valid
81 /* record attribute header, update message length */ fm10k_tlv_attr_put_null_string()
93 * fm10k_tlv_attr_get_null_string - Get null terminated string from attribute
94 * @attr: Pointer to attribute
97 * This function pulls the string back out of the attribute and will place
119 * fm10k_tlv_attr_put_mac_vlan - Store MAC/VLAN attribute in message
125 * in the attribute buffer. It will return success if provided with a
140 /* record attribute header, update message length */ fm10k_tlv_attr_put_mac_vlan()
156 * fm10k_tlv_attr_get_mac_vlan - Get MAC/VLAN stored in attribute
157 * @attr: Pointer to attribute
161 * This function pulls the MAC address back out of the attribute and will
183 * This function will simply add an attribute header, the fact
184 * that the header is here means the attribute value is true, else
194 /* record attribute header */ fm10k_tlv_attr_put_bool()
204 * fm10k_tlv_attr_put_value - Store integer value attribute in message
211 * in a message attribute. The function will return success provided
232 /* record attribute header, update message length */ fm10k_tlv_attr_put_value()
244 * fm10k_tlv_attr_get_value - Get integer value stored in attribute
245 * @attr: Pointer to attribute
252 * attribute length.
283 * attribute. The function will return success provided that all pointers
303 /* record attribute header, update message length */ fm10k_tlv_attr_put_le_struct()
315 * fm10k_tlv_attr_get_le_struct - Get little endian struct form attribute
316 * @attr: Pointer to attribute
323 * attribute length.
404 * fm10k_tlv_attr_validate - Validate attribute metadata
405 * @attr: Pointer to attribute
406 * @tlv_attr: Type and length info for attribute
411 * return FM10K_ERR_PARAM if any attribute is malformed, otherwise
420 /* verify this is an attribute and not a message */ fm10k_tlv_attr_validate()
432 /* move to start of attribute data */ fm10k_tlv_attr_validate()
467 /* attribute id is mapped to bad value */ fm10k_tlv_attr_validate()
475 * fm10k_tlv_attr_parse - Parses stream of attribute data
476 * @attr: Pointer to attribute list
483 * FM10K_NOT_IMPLEMENTED for any attribute that is outside of the array
508 /* no attributes to parse, just raw data, message becomes attribute */ fm10k_tlv_attr_parse()
514 /* move to start of attribute data */ fm10k_tlv_attr_parse()
534 /* move to next attribute */ fm10k_tlv_attr_parse()
570 /* verify this is a message and not an attribute */ fm10k_tlv_msg_parse()
651 * This function is meant to load a message buffer with attribute data
687 * This function is meant to load a message buffer with all attribute types
688 * including a nested attribute.
/linux-4.1.27/net/irda/
H A Dirias_object.c88 * Delete given attribute and deallocate all its memory
148 * Remove attribute from hashbin and, if it was the last attribute of
161 /* Remove attribute from object */ irias_delete_attrib()
166 /* Deallocate attribute */ irias_delete_attrib()
214 * Find named attribute in object
236 * Add attribute to object
257 * Change the value of an objects attribute.
278 /* Find attribute */ irias_object_change_attribute()
281 net_warn_ratelimited("%s: Unable to find attribute: %s\n", irias_object_change_attribute()
309 * Add an integer attribute to an LM-IAS object
323 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_integer_attrib()
334 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_integer_attrib()
350 * Add a octet sequence attribute to an LM-IAS object
367 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_octseq_attrib()
377 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_octseq_attrib()
393 * Add a string attribute to an LM-IAS object
409 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_string_attrib()
419 net_warn_ratelimited("%s: Unable to allocate attribute!\n", irias_add_string_attrib()
/linux-4.1.27/fs/xfs/libxfs/
H A Dxfs_attr.c47 * Provide the external interfaces to manage attribute lists.
55 * Internal routines when attribute list fits inside the inode.
60 * Internal routines when attribute list is one block.
67 * Internal routines when attribute list is more than one block.
159 * Calculate how many blocks we need for the new attribute,
171 * Determine space new attribute will use, and if it would be xfs_attr_calc_size()
183 * Out of line attribute, cannot double split, but xfs_attr_calc_size()
184 * make room for the attribute value itself. xfs_attr_calc_size()
231 * If the inode doesn't have an attribute fork, add one. xfs_attr_set()
286 * If the attribute list is non-existent or a shortform list, xfs_attr_set()
287 * upgrade it to a single-leaf-block attribute list. xfs_attr_set()
294 * Build initial attribute list (if required). xfs_attr_set()
300 * Try to add the attr to the attribute list in xfs_attr_set()
356 * transaction to add the new attribute to the leaf. xfs_attr_set()
401 * Generic handler routine to remove a name from an attribute list.
402 * Transitions attribute list from Btree to shortform as necessary.
432 * we have no control over the attribute names that userspace passes us xfs_attr_remove()
433 * to remove, so we have to allow the name lookup prior to attribute xfs_attr_remove()
519 * External routines when attribute list is inside the inode
523 * Add a name to the shortform attribute list structure
560 * External routines when attribute list is one block
564 * Add a name to the leaf attribute list structure
579 * Read the (only) block in the attribute list in. xfs_attr_leaf_addname()
588 * Look up the given attribute in the leaf block. Figure out if xfs_attr_leaf_addname()
603 /* save the attribute state for later removal*/ xfs_attr_leaf_addname()
613 * values reflect the state of the attribute we are about to xfs_attr_leaf_addname()
614 * add, not the attribute we just found and will remove later. xfs_attr_leaf_addname()
622 * Add the attribute to the leaf block, transitioning to a Btree xfs_attr_leaf_addname()
628 * Promote the attribute list to the Btree format, then xfs_attr_leaf_addname()
678 * after we create the attribute so that we don't overflow the xfs_attr_leaf_addname()
689 * incomplete flags on the "new" and "old" attribute/value pairs xfs_attr_leaf_addname()
691 * must remove the "old" attribute/value pair. xfs_attr_leaf_addname()
703 * Dismantle the "old" attribute/value pair by removing xfs_attr_leaf_addname()
771 * Remove a name from the leaf attribute list structure
786 * Remove the attribute. xfs_attr_leaf_removename()
831 * Look up a name in a leaf attribute list structure.
863 * External routines when attribute list size > geo->blksize
867 * Add a name to a Btree-format attribute list.
873 * "Remote" attribute values confuse the issue and atomic rename operations
914 /* save the attribute state for later removal*/ xfs_attr_node_addname()
924 * values reflect the state of the attribute we are about to xfs_attr_node_addname()
925 * add, not the attribute we just found and will remove later. xfs_attr_node_addname()
1025 * after we create the attribute so that we don't overflow the xfs_attr_node_addname()
1036 * incomplete flags on the "new" and "old" attribute/value pairs xfs_attr_node_addname()
1038 * must remove the "old" attribute/value pair. xfs_attr_node_addname()
1050 * Dismantle the "old" attribute/value pair by removing xfs_attr_node_addname()
1065 * Re-find the "old" attribute entry after any split ops. xfs_attr_node_addname()
1139 * Remove a name from a B-tree attribute list.
1176 * This is done before we remove the attribute so that we don't xfs_attr_node_removename()
1193 * Mark the attribute as INCOMPLETE, then bunmapi() the xfs_attr_node_removename()
1405 * Look up a filename in a node attribute list.
1407 * This routine gets called for any attribute fork that has more than one
H A Dxfs_attr_remote.c47 * Each contiguous block has a header, so it is not just a simple attribute
63 * Checking of the remote attribute header is split into two parts. The verifier
65 * attribute parameters and owner.
230 * Remote attribute blocks are written synchronously, so we don't xfs_attr3_rmt_hdr_set()
245 * Helper functions to copy attribute data in and out of the one disk extents
273 "remote attribute header mismatch bno/off/len/owner (0x%llx/0x%x/Ox%x/0x%llx)", xfs_attr_rmtval_copyout()
287 /* roll attribute data forwards */ xfs_attr_rmtval_copyout()
337 /* roll attribute data forwards */ xfs_attr_rmtval_copyin()
345 * Read the value associated with an attribute from the out-of-line buffer
400 /* roll attribute extent map forwards */ xfs_attr_rmtval_get()
410 * Write the value associated with an attribute into the out-of-line buffer
432 * Find a "hole" in the attribute address space large enough for xfs_attr_rmtval_set()
433 * us to drop the new attribute's value into. Because CRC enable xfs_attr_rmtval_set()
456 * write the remote attribute without logging the contents. xfs_attr_rmtval_set()
502 * Roll through the "value", copying the attribute value to the xfs_attr_rmtval_set()
545 /* roll attribute extent map forwards */ xfs_attr_rmtval_set()
554 * Remove the value associated with an attribute by deleting the
570 * Roll through the "value", invalidating the attribute value's blocks. xfs_attr_rmtval_remove()
H A Dxfs_trans_resv.h50 struct xfs_trans_res tr_attrsetm; /* set/create an attribute at
52 struct xfs_trans_res tr_attrsetrt; /* set/create an attribute at
54 struct xfs_trans_res tr_attrrm; /* remove an attribute */
H A Dxfs_attr_leaf.h45 * Internal routines when attribute fork size < XFS_LITINO(mp).
59 * Internal routines when attribute fork size == XFS_LBSIZE(mp).
H A Dxfs_da_format.h29 #define XFS_ATTR_LEAF_MAGIC 0xfbee /* magic number: attribute leaf blks */
49 #define XFS_ATTR3_LEAF_MAGIC 0x3bee /* magic number: attribute leaf blks */
614 * of an attribute name may not be unique, we may have duplicate keys. The
629 * nodes until the hash key changes or the attribute name is found.
631 * We store the fact that an attribute is a ROOT/USER/SECURE attribute in
633 * at the namespace bit when we are looking for a matching attribute name.
636 * attribute is in the middle of being created and should not be shown to
638 * bit when we have finished setting up the attribute. We do this because
697 * attr2 is already taken by the variable inode attribute fork size feature.
727 * incore, neutral version of the attribute leaf header
852 * Remote attribute block format definition
854 * There is one of these headers per filesystem block in a remote attribute.
855 * This is done to ensure there is a 1:1 mapping between the attribute value
856 * length and the number of blocks needed to store the attribute. This makes the
859 * the number of blocks needed to store the attribute data.
H A Dxfs_attr_leaf.c365 * External routines when attribute fork size < XFS_LITINO(mp).
370 * attribute space will be able to fit inline.
373 * literal area for attribute data once the new bytes have been added.
401 * current attribute fork size we can always proceed. xfs_attr_shortform_bytesfit()
415 * space in the fixed attribute fork. xfs_attr_shortform_bytesfit()
489 * Create the initial contents of a shortform attribute list.
520 * Add a name/value pair to the shortform attribute list.
574 * After the last attribute is removed revert to original inode format,
593 * Remove an attribute from the shortform attribute list structure.
627 * Fix up the attribute fork data, covering the hole xfs_attr_shortform_remove()
637 * Fix up the start offset of the attribute fork xfs_attr_shortform_remove()
663 * Look up a name in a shortform attribute list structure.
694 * Look up a name in a shortform attribute list structure.
822 * Check a leaf attribute block to see if all the entries would fit into
823 * a shortform attribute list.
865 * Convert a leaf attribute list to shortform attribute list
899 * Clean out the prior contents of the attribute list. xfs_attr3_leaf_to_shortform()
1022 * Create the initial contents of a leaf attribute list
1023 * or a leaf in a node attribute list.
1112 * Save info on "old" attribute for "atomic rename" ops, leaf_add() xfs_attr3_leaf_split()
1135 * Add a name to the leaf attribute list structure.
1214 * Add a name to a leaf attribute list structure.
1283 * For "remote" attribute values, simply note that we need to xfs_attr3_leaf_add_work()
1334 * Garbage collect a leaf attribute list block by copying it to a new buffer.
1432 * Redistribute the attribute list entries between two leaf nodes,
1439 * to match what it is doing in splitting the attribute leaf block. Those
1804 * to shrink an attribute list over time. xfs_attr3_leaf_toosmall()
1862 * Remove a name from the leaf attribute list structure.
2019 * Move all the attribute list entries from drop_leaf into save_leaf.
2135 * Look up a name in a leaf attribute list structure.
2145 * Don't change the args->value unless we find the attribute.
2254 * Get the value associated with an attribute name from a leaf attribute
2374 * but allocate attribute info packed and in sequence. xfs_attr3_leaf_moveents()
2483 * Calculate the number of bytes used to store the indicated attribute
2508 * attribute (whether local or remote only calculate bytes in this block).
2509 * This routine decides as a side effect whether the attribute will be
2510 * a "local" or a "remote" attribute.
/linux-4.1.27/fs/configfs/
H A Dfile.c37 * A simple attribute can only be 4096 characters. Why 4k? Because the
39 * because an attribute of 16k on ia64 won't work on x86. So we limit to
60 * config_item's show() method to fill the buffer with this attribute's
88 * configfs_read_file - read an attribute.
94 * Userspace wants to read an attribute file. The attribute descriptor
101 * all the data the item has to offer for that attribute.
160 * @dentry: dentry to the attribute
164 * Get the correct pointers for the config_item and the attribute we're
165 * dealing with, then call the store() method for the attribute,
181 * configfs_write_file - write an attribute.
224 /* Grab the module reference for this attribute if we have one */ check_perm()
317 * configfs_create_file - create an attribute file for an item.
/linux-4.1.27/net/netlabel/
H A Dnetlabel_cipso_v4.h123 * attribute */
127 * NLBL_CIPSOV4_A_TAG attribute, tags listed first are given higher
137 * a MLS sensitivity level mapping, must contain only one attribute of
143 * NLBL_CIPSOV4_A_MLSLVL attribute */
152 * a MLS category mapping, must contain only one attribute of each of
158 * NLBL_CIPSOV4_A_MLSCAT attribute */
H A Dnetlabel_mgmt.h81 * If the IP address selectors are not used the following attribute is
123 * If the IP address selectors are not used the following attribute is
207 * attribute plus any protocol specific attributes */
211 * NLBL_MGMT_A_ADDRSELECTOR attribute */
/linux-4.1.27/fs/9p/
H A Dxattr.c63 * Copy an extended attribute into the buffer
87 * Create, replace or remove an extended attribute for this inode. Buffer
88 * is NULL to remove an existing extended attribute, and non-NULL to
89 * either replace an existing extended attribute, or create a new extended
90 * attribute. The flags XATTR_REPLACE and XATTR_CREATE
91 * specify that an extended attribute must exist and must not exist
H A Dv9fs.h193 * issuing a attribute request
195 * @fid: fid to issue attribute request for
211 * issuing a attribute request
213 * @fid: fid to issue attribute request for
/linux-4.1.27/drivers/net/wireless/libertas/
H A Dmesh.c151 * lbs_anycast_get - Get function for sysfs attribute anycast_mask
173 * lbs_anycast_set - Set function for sysfs attribute anycast_mask
176 * @buf: buffer that contains new attribute value
199 * lbs_prb_rsp_limit_get - Get function for sysfs attribute prb_rsp_limit
225 * lbs_prb_rsp_limit_set - Set function for sysfs attribute prb_rsp_limit
228 * @buf: buffer that contains new attribute value
258 * lbs_mesh_get - Get function for sysfs attribute mesh
271 * lbs_mesh_set - Set function for sysfs attribute mesh
274 * @buf: buffer that contains new attribute value
297 * lbs_mesh attribute to be exported per ethX interface
303 * anycast_mask attribute to be exported per mshX interface
309 * prb_rsp_limit attribute to be exported per mshX interface
315 static struct attribute *lbs_mesh_sysfs_entries[] = {
350 * bootflag_get - Get function for sysfs attribute bootflag
370 * bootflag_set - Set function for sysfs attribute bootflag
373 * @buf: buffer that contains new attribute value
400 * boottime_get - Get function for sysfs attribute boottime
420 * boottime_set - Set function for sysfs attribute boottime
423 * @buf: buffer that contains new attribute value
459 * channel_get - Get function for sysfs attribute channel
479 * channel_set - Set function for sysfs attribute channel
482 * @buf: buffer that contains new attribute value
509 * mesh_id_get - Get function for sysfs attribute mesh_id
538 * mesh_id_set - Set function for sysfs attribute mesh_id
541 * @buf: buffer that contains new attribute value
584 * protocol_id_get - Get function for sysfs attribute protocol_id
604 * protocol_id_set - Set function for sysfs attribute protocol_id
607 * @buf: buffer that contains new attribute value
645 * metric_id_get - Get function for sysfs attribute metric_id
665 * metric_id_set - Set function for sysfs attribute metric_id
668 * @buf: buffer that contains new attribute value
706 * capability_get - Get function for sysfs attribute capability
726 * capability_set - Set function for sysfs attribute capability
729 * @buf: buffer that contains new attribute value
775 static struct attribute *boot_opts_attrs[] = {
787 static struct attribute *mesh_ie_attrs[] = {
882 netdev_err(priv->dev, "cannot register lbs_mesh attribute\n"); lbs_start_mesh()
/linux-4.1.27/net/core/
H A Dnet-sysfs.c473 static struct attribute *net_class_attrs[] = {
504 /* Show a given an attribute in the statistics group */ netstat_show()
526 /* generate a read-only statistics attribute */
560 static struct attribute *netstat_attrs[] = {
594 static struct attribute *wireless_attrs[] = {
614 static ssize_t rx_queue_attr_show(struct kobject *kobj, struct attribute *attr, rx_queue_attr_show()
617 struct rx_queue_attribute *attribute = to_rx_queue_attr(attr); rx_queue_attr_show() local
620 if (!attribute->show) rx_queue_attr_show()
623 return attribute->show(queue, attribute, buf); rx_queue_attr_show()
626 static ssize_t rx_queue_attr_store(struct kobject *kobj, struct attribute *attr, rx_queue_attr_store()
629 struct rx_queue_attribute *attribute = to_rx_queue_attr(attr); rx_queue_attr_store() local
632 if (!attribute->store) rx_queue_attr_store()
635 return attribute->store(queue, attribute, buf, count); rx_queue_attr_store()
645 struct rx_queue_attribute *attribute, char *buf) show_rps_map()
668 struct rx_queue_attribute *attribute, store_rps_map()
814 static struct attribute *rx_queue_default_attrs[] = {
931 struct attribute attr;
943 struct attribute *attr, char *buf) netdev_queue_attr_show()
945 struct netdev_queue_attribute *attribute = to_netdev_queue_attr(attr); netdev_queue_attr_show() local
948 if (!attribute->show) netdev_queue_attr_show()
951 return attribute->show(queue, attribute, buf); netdev_queue_attr_show()
955 struct attribute *attr, netdev_queue_attr_store()
958 struct netdev_queue_attribute *attribute = to_netdev_queue_attr(attr); netdev_queue_attr_store() local
961 if (!attribute->store) netdev_queue_attr_store()
964 return attribute->store(queue, attribute, buf, count); netdev_queue_attr_store()
973 struct netdev_queue_attribute *attribute, show_trans_timeout()
1001 struct netdev_queue_attribute *attribute, show_tx_maxrate()
1008 struct netdev_queue_attribute *attribute, set_tx_maxrate()
1082 struct netdev_queue_attribute *attribute, bql_set_hold_time()
1137 static struct attribute *dql_attrs[] = {
1154 struct netdev_queue_attribute *attribute, char *buf) show_xps_map()
1192 struct netdev_queue_attribute *attribute, store_xps_map()
1225 static struct attribute *netdev_queue_default_attrs[] = {
644 show_rps_map(struct netdev_rx_queue *queue, struct rx_queue_attribute *attribute, char *buf) show_rps_map() argument
667 store_rps_map(struct netdev_rx_queue *queue, struct rx_queue_attribute *attribute, const char *buf, size_t len) store_rps_map() argument
972 show_trans_timeout(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, char *buf) show_trans_timeout() argument
1000 show_tx_maxrate(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, char *buf) show_tx_maxrate() argument
1007 set_tx_maxrate(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, const char *buf, size_t len) set_tx_maxrate() argument
1081 bql_set_hold_time(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, const char *buf, size_t len) bql_set_hold_time() argument
1153 show_xps_map(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, char *buf) show_xps_map() argument
1191 store_xps_map(struct netdev_queue *queue, struct netdev_queue_attribute *attribute, const char *buf, size_t len) store_xps_map() argument
/linux-4.1.27/drivers/md/bcache/
H A Dsysfs.h15 static ssize_t fn ## _show(struct kobject *kobj, struct attribute *attr,\
19 static ssize_t fn ## _store(struct kobject *kobj, struct attribute *attr,\
43 static struct attribute sysfs_##_name = \
/linux-4.1.27/drivers/video/console/
H A Dbitblit.c25 static void update_attr(u8 *dst, u8 *src, int attribute, update_attr() argument
36 if (attribute & FBCON_ATTRIBUTE_UNDERLINE && i >= offset) update_attr()
38 if (attribute & FBCON_ATTRIBUTE_BOLD) update_attr()
40 if (attribute & FBCON_ATTRIBUTE_REVERSE) update_attr()
154 u32 attribute = get_attribute(info, scr_readw(s)); bit_putcs() local
164 if (attribute) { bit_putcs()
185 bit_putcs_aligned(vc, info, s, attribute, cnt, pitch, bit_putcs()
188 bit_putcs_unaligned(vc, info, s, attribute, cnt, bit_putcs()
244 int attribute, use_sw = (vc->vc_cursor_type & 0x10); bit_cursor() local
260 attribute = get_attribute(info, c); bit_cursor()
269 if (attribute) { bit_cursor()
277 update_attr(dst, src, attribute, vc); bit_cursor()
H A Dfbcon_ccw.c25 static void ccw_update_attr(u8 *dst, u8 *src, int attribute, ccw_update_attr() argument
43 if (attribute & FBCON_ATTRIBUTE_UNDERLINE) { ccw_update_attr()
51 if (attribute & FBCON_ATTRIBUTE_BOLD && i) ccw_update_attr()
54 if (attribute & FBCON_ATTRIBUTE_REVERSE) ccw_update_attr()
141 u32 attribute = get_attribute(info, scr_readw(s)); ccw_putcs() local
155 if (attribute) { ccw_putcs()
176 ccw_putcs_aligned(vc, info, s, attribute, cnt, pitch, ccw_putcs()
229 int attribute, use_sw = (vc->vc_cursor_type & 0x10); ccw_cursor() local
249 attribute = get_attribute(info, c); ccw_cursor()
258 if (attribute) { ccw_cursor()
266 ccw_update_attr(dst, src, attribute, vc); ccw_cursor()
H A Dfbcon_cw.c25 static void cw_update_attr(u8 *dst, u8 *src, int attribute, cw_update_attr() argument
35 if (attribute & FBCON_ATTRIBUTE_UNDERLINE && !j) cw_update_attr()
37 if (attribute & FBCON_ATTRIBUTE_BOLD && i) cw_update_attr()
39 if (attribute & FBCON_ATTRIBUTE_REVERSE) cw_update_attr()
126 u32 attribute = get_attribute(info, scr_readw(s)); cw_putcs() local
140 if (attribute) { cw_putcs()
159 cw_putcs_aligned(vc, info, s, attribute, cnt, pitch, cw_putcs()
212 int attribute, use_sw = (vc->vc_cursor_type & 0x10); cw_cursor() local
232 attribute = get_attribute(info, c); cw_cursor()
241 if (attribute) { cw_cursor()
249 cw_update_attr(dst, src, attribute, vc); cw_cursor()
H A Dfbcon_ud.c25 static void ud_update_attr(u8 *dst, u8 *src, int attribute, ud_update_attr() argument
37 if (attribute & FBCON_ATTRIBUTE_UNDERLINE && i < offset) ud_update_attr()
39 if (attribute & FBCON_ATTRIBUTE_BOLD) ud_update_attr()
41 if (attribute & FBCON_ATTRIBUTE_REVERSE) ud_update_attr()
163 u32 attribute = get_attribute(info, scr_readw(s)); ud_putcs() local
178 if (attribute) { ud_putcs()
201 ud_putcs_aligned(vc, info, s, attribute, cnt, pitch, ud_putcs()
204 ud_putcs_unaligned(vc, info, s, attribute, cnt, pitch, ud_putcs()
259 int attribute, use_sw = (vc->vc_cursor_type & 0x10); ud_cursor() local
280 attribute = get_attribute(info, c); ud_cursor()
289 if (attribute) { ud_cursor()
297 ud_update_attr(dst, src, attribute, vc); ud_cursor()
H A Dfbcon.h237 int attribute = 0; get_attribute() local
241 attribute |= FBCON_ATTRIBUTE_UNDERLINE; get_attribute()
243 attribute |= FBCON_ATTRIBUTE_REVERSE; get_attribute()
245 attribute |= FBCON_ATTRIBUTE_BOLD; get_attribute()
248 return attribute; get_attribute()
/linux-4.1.27/drivers/md/
H A Ddm-sysfs.c12 struct attribute attr;
21 static ssize_t dm_attr_show(struct kobject *kobj, struct attribute *attr, dm_attr_show()
46 static ssize_t dm_attr_store(struct kobject *kobj, struct attribute *attr, dm_attr_store()
105 static struct attribute *dm_attrs[] = {
/linux-4.1.27/arch/mips/include/asm/mach-ip27/
H A Dspaces.h14 * IP27 uses the R10000's uncached attribute feature. Attribute 3 selects
/linux-4.1.27/fs/ocfs2/cluster/
H A Dmasklog.c68 struct attribute attr;
105 static struct attribute *mlog_attr_ptrs[MLOG_MAX_BITS] = {NULL, };
107 static ssize_t mlog_show(struct kobject *obj, struct attribute *attr, mlog_show()
115 static ssize_t mlog_store(struct kobject *obj, struct attribute *attr, mlog_store()
H A Dsys.c46 static struct attribute *o2cb_attrs[] = {
/linux-4.1.27/arch/ia64/include/asm/
H A Dagp.h12 * To avoid memory-attribute aliasing issues, we require that the AGPGART engine operate
/linux-4.1.27/fs/f2fs/
H A Dxattr.h23 /* Magic value in attribute blocks */
26 /* Maximum number of references to one attribute block */
48 __le16 e_value_size; /* size of attribute value */
49 char e_name[0]; /* attribute name */
/linux-4.1.27/drivers/edac/
H A Dedac_device_sysfs.c28 * Set of edac_device_ctl_info attribute store/show functions
106 /* edac_device_ctl_info specific attribute structure */
108 struct attribute attr;
118 struct attribute *attr, char *buffer) edac_dev_ctl_info_show()
130 struct attribute *attr, edac_dev_ctl_info_store()
220 .default_attrs = (struct attribute **)device_ctrl_attr,
315 * Set of low-level instance attribute show functions
346 /* instance specific attribute structure */
348 struct attribute attr;
355 struct attribute *attr, char *buffer) edac_dev_instance_show()
367 struct attribute *attr, edac_dev_instance_store()
410 .default_attrs = (struct attribute **)device_instance_attr,
420 * Set of low-level block attribute show functions
423 struct attribute *attr, char *data) block_ue_count_show()
431 struct attribute *attr, char *data) block_ce_count_show()
457 struct attribute *attr, char *buffer) edac_dev_block_show()
469 struct attribute *attr, edac_dev_block_store()
508 .default_attrs = (struct attribute **)device_block_attr,
601 (struct attribute *) sysfs_attrib); edac_device_delete_block()
756 /* iterate over the array and create an attribute for each edac_device_add_main_sysfs_attributes()
761 (struct attribute*) sysfs_attrib); edac_device_add_main_sysfs_attributes()
784 * removing each attribute listed from this device's instance's kobject edac_device_remove_main_sysfs_attributes()
790 (struct attribute *) sysfs_attrib); edac_device_remove_main_sysfs_attributes()
H A Damd64_edac_dbg.c43 static struct attribute *amd64_edac_dbg_attrs[] = {
H A Dedac_mc_sysfs.c165 /* Set of more default csrow<id> attribute show/store functions */ csrow_ue_count_show()
253 /* show function for dynamic chX_ce_count attribute */ channel_ce_count_show()
264 /* cwrow<id>/attribute files */
273 static struct attribute *csrow_attrs[] = {
306 * possible dynamic channel DIMM Label attribute files
325 /* Total possible dynamic DIMM Label attribute file table */
326 static struct attribute *dynamic_csrow_dimm_attr[] = {
336 /* possible dynamic channel ce_count attribute files */
350 /* Total possible dynamic ce_count attribute file table */
351 static struct attribute *dynamic_csrow_ce_count_attr[] = {
362 struct attribute *attr, int idx) csrow_dev_is_visible()
545 /* dimm/rank attribute files */
555 static struct attribute *dimm_attrs[] = {
701 /* default attribute files for the MCI object */ mci_ue_count_show()
847 /* memory scrubber attribute file */
851 static struct attribute *mci_attrs[] = {
866 struct attribute *attr, int idx) mci_attr_is_visible()
H A Dedac_pci_sysfs.c89 /* instance specific attribute structure */
91 struct attribute attr;
98 struct attribute *attr, char *buffer) edac_pci_instance_show()
110 struct attribute *attr, edac_pci_instance_store()
148 .default_attrs = (struct attribute **)pci_instance_attr,
231 struct attribute attr;
238 static ssize_t edac_pci_dev_show(struct kobject *kobj, struct attribute *attr, edac_pci_dev_show()
250 struct attribute *attr, const char *buffer, edac_pci_dev_store()
330 .default_attrs = (struct attribute **)edac_pci_attr,
/linux-4.1.27/kernel/
H A Dparams.c537 struct param_attribute *attribute = to_param_attr(mattr); param_attr_show() local
539 if (!attribute->param->ops->get) param_attr_show()
543 count = attribute->param->ops->get(buf, attribute->param); param_attr_show()
558 struct param_attribute *attribute = to_param_attr(mattr); param_attr_store() local
560 if (!attribute->param->ops->set) param_attr_store()
564 param_check_unsafe(attribute->param); param_attr_store()
565 err = attribute->param->ops->set(buf, attribute->param); param_attr_store()
607 struct attribute **new_attrs; add_sysfs_param()
619 /* NULL-terminated attribute array. */ add_sysfs_param()
865 struct attribute *attr, module_attr_show()
868 struct module_attribute *attribute; module_attr_show() local
872 attribute = to_module_attr(attr); module_attr_show()
875 if (!attribute->show) module_attr_show()
878 ret = attribute->show(attribute, mk, buf); module_attr_show()
884 struct attribute *attr, module_attr_store()
887 struct module_attribute *attribute; module_attr_store() local
891 attribute = to_module_attr(attr); module_attr_store()
894 if (!attribute->store) module_attr_store()
897 ret = attribute->store(attribute, mk, buf, len); module_attr_store()
/linux-4.1.27/drivers/cpuidle/
H A Dsysfs.c121 static struct attribute *cpuidle_default_attrs[] = {
131 static struct attribute *cpuidle_switch_attrs[] = {
163 struct attribute attr;
189 static ssize_t cpuidle_show(struct kobject *kobj, struct attribute *attr, cpuidle_show()
204 static ssize_t cpuidle_store(struct kobject *kobj, struct attribute *attr, cpuidle_store()
238 struct attribute attr;
314 static struct attribute *cpuidle_state_default_attrs[] = {
338 static ssize_t cpuidle_state_show(struct kobject *kobj, struct attribute *attr, cpuidle_state_show()
352 static ssize_t cpuidle_state_store(struct kobject *kobj, struct attribute *attr, cpuidle_state_store()
458 struct attribute attr;
480 static ssize_t cpuidle_driver_show(struct kobject *kobj, struct attribute *attr, cpuidle_driver_show()
493 static ssize_t cpuidle_driver_store(struct kobject *kobj, struct attribute *attr, cpuidle_driver_store()
513 static struct attribute *cpuidle_driver_default_attrs[] = {
525 * cpuidle_add_driver_sysfs - adds the driver name sysfs attribute
556 * cpuidle_remove_driver_sysfs - removes the driver name sysfs attribute
/linux-4.1.27/arch/x86/kernel/cpu/mcheck/
H A Dmce-internal.h23 struct device_attribute attr; /* device attribute */
24 char attrname[ATTR_LEN]; /* attribute name */
/linux-4.1.27/drivers/net/wireless/
H A Dmac80211_hwsim.h94 * @HWSIM_ATTR_UNSPEC: unspecified attribute to catch errors
109 * @HWSIM_ATTR_CHANNELS: u32 attribute used with the %HWSIM_CMD_CREATE_RADIO
111 * @HWSIM_ATTR_RADIO_ID: u32 attribute used with %HWSIM_CMD_DESTROY_RADIO
115 * @HWSIM_ATTR_REG_CUSTOM_REG: custom regulatory domain index (u32 attribute)
116 * @HWSIM_ATTR_REG_STRICT_REG: request REGULATORY_STRICT_REG (flag attribute)
H A Dray_cs.h30 void __iomem *amem; /* pointer to attribute mem window */
/linux-4.1.27/fs/nilfs2/
H A Dsysfs.h64 struct attribute attr; \
65 ssize_t (*show)(struct kobject *, struct attribute *, \
67 ssize_t (*store)(struct kobject *, struct attribute *, \
75 struct attribute attr; \
91 struct attribute attr; \
H A Dsysfs.c46 struct attribute *attr, char *buf) \
57 struct attribute *attr, \
150 static struct attribute *nilfs_snapshot_attrs[] = {
158 struct attribute *attr, char *buf) nilfs_snapshot_attr_show()
169 struct attribute *attr, nilfs_snapshot_attr_store()
249 static struct attribute *nilfs_mounted_snapshots_attrs[] = {
358 static struct attribute *nilfs_checkpoints_attrs[] = {
447 static struct attribute *nilfs_segments_attrs[] = {
700 static struct attribute *nilfs_segctor_attrs[] = {
835 static struct attribute *nilfs_superblock_attrs[] = {
941 static struct attribute *nilfs_dev_attrs[] = {
953 struct attribute *attr, char *buf) nilfs_dev_attr_show()
964 struct attribute *attr, nilfs_dev_attr_store()
1073 struct attribute *attr, char *buf) nilfs_feature_revision_show()
1085 struct attribute *attr, nilfs_feature_README_show()
1094 static struct attribute *nilfs_feature_attrs[] = {
/linux-4.1.27/include/target/
H A Dconfigfs_macros.h44 * Users often need to create attribute structures for their configurable
46 * for the show() and store() operations on that attribute. If they don't
47 * need anything else on the extended attribute structure, they can use
61 * With the extended attribute structure, users can use this macro
93 * them. The argument _name is the name of the attribute defined by
/linux-4.1.27/drivers/pci/
H A Dpci-label.c42 enum smbios_attr_enum attribute) find_smbios_instance_string()
59 if (attribute == SMBIOS_ATTR_INSTANCE_SHOW) find_smbios_instance_string()
63 else if (attribute == SMBIOS_ATTR_LABEL_SHOW) find_smbios_instance_string()
75 struct attribute *attr, int n) smbios_instance_string_exist()
117 static struct attribute *smbios_attributes[] = {
220 struct attribute *attr, int n) acpi_index_string_exist()
254 static struct attribute *acpi_attributes[] = {
41 find_smbios_instance_string(struct pci_dev *pdev, char *buf, enum smbios_attr_enum attribute) find_smbios_instance_string() argument
H A Dslot.c19 struct attribute *attr, char *buf) pci_slot_attr_show()
22 struct pci_slot_attribute *attribute = to_pci_slot_attr(attr); pci_slot_attr_show() local
23 return attribute->show ? attribute->show(slot, buf) : -EIO; pci_slot_attr_show()
27 struct attribute *attr, const char *buf, size_t len) pci_slot_attr_store()
30 struct pci_slot_attribute *attribute = to_pci_slot_attr(attr); pci_slot_attr_store() local
31 return attribute->store ? attribute->store(slot, buf, len) : -EIO; pci_slot_attr_store()
125 static struct attribute *pci_slot_default_attrs[] = {
/linux-4.1.27/drivers/base/
H A Dsoc.c46 struct attribute *attr, soc_attribute_mode()
65 /* Unknown or unfilled attribute. */ soc_attribute_mode()
88 static struct attribute *soc_attr[] = {
H A Dattribute_container.c68 * attribute_container_register - register an attribute container
346 * attribute containers, namely add the classdev to the system and then
347 * create the attribute files
374 * attribute_container_remove_attrs - remove any attribute files
404 * This function simply removes all the attribute files and then calls
/linux-4.1.27/arch/ia64/kernel/
H A Defi.c256 if (!(md->attribute & EFI_MEMORY_WB)) is_memory_available()
271 u64 attribute; member in struct:kern_memdesc
295 return (md->attribute & EFI_MEMORY_WB); efi_wb()
301 return (md->attribute & EFI_MEMORY_UC); efi_uc()
312 if (k->attribute != attr) walk()
617 if (md->attribute & EFI_MEMORY_RUNTIME) { efi_enter_virtual_mode()
622 if (md->attribute & EFI_MEMORY_WB) { efi_enter_virtual_mode()
624 } else if (md->attribute & EFI_MEMORY_UC) { efi_enter_virtual_mode()
626 } else if (md->attribute & EFI_MEMORY_WC) { efi_enter_virtual_mode()
639 } else if (md->attribute & EFI_MEMORY_WT) { efi_enter_virtual_mode()
702 if (md->attribute & EFI_MEMORY_UC) efi_get_iobase()
779 return md->attribute; efi_mem_attributes()
795 * EFI_MEMORY_RUNTIME is not a memory attribute; it just tells efi_mem_attribute()
798 attr = md->attribute & ~EFI_MEMORY_RUNTIME; efi_mem_attribute()
806 if (!md || (md->attribute & ~EFI_MEMORY_RUNTIME) != attr) efi_mem_attribute()
834 attr = md->attribute; kern_mem_attribute()
842 if (!md || md->attribute != attr) kern_mem_attribute()
877 * attribute. valid_mmap_phys_addr_range()
904 * we must use the same attribute as the kernel mapping. phys_mem_access_prot()
1071 k->attribute = EFI_MEMORY_UC; efi_memmap_init()
1104 (k-1)->attribute == EFI_MEMORY_UC && efi_memmap_init()
1110 k->attribute = EFI_MEMORY_UC; efi_memmap_init()
1125 (k-1)->attribute == EFI_MEMORY_UC && efi_memmap_init()
1129 k->attribute = EFI_MEMORY_UC; efi_memmap_init()
1157 k->attribute = EFI_MEMORY_WB; efi_memmap_init()
1208 if (md->attribute & EFI_MEMORY_WP) { efi_initialize_iomem_resources()
1211 } else if (md->attribute == EFI_MEMORY_UC) efi_initialize_iomem_resources()
/linux-4.1.27/security/integrity/evm/
H A Devm_main.c265 * evm_protect_xattr - protect the EVM extended attribute
322 * evm_inode_setxattr - protect the EVM extended attribute
324 * @xattr_name: pointer to the affected extended attribute name
325 * @xattr_value: pointer to the new extended attribute value
326 * @xattr_value_len: pointer to the new extended attribute value length
350 * evm_inode_removexattr - protect the EVM extended attribute
352 * @xattr_name: pointer to the affected extended attribute name
365 * @xattr_name: pointer to the affected extended attribute name
366 * @xattr_value: pointer to the new extended attribute value
367 * @xattr_value_len: pointer to the new extended attribute value length
388 * @xattr_name: pointer to the affected extended attribute name
405 * evm_inode_setattr - prevent updating an invalid EVM extended attribute
/linux-4.1.27/drivers/staging/rtl8723au/core/
H A Drtw_ieee80211.c599 * rtw_get_wps_attr23a - Search a specific WPS attribute from a given WPS IE
602 * @target_attr_id: The attribute ID of WPS attribute to search
603 * @buf_attr: If not NULL and the WPS attribute is found, WPS attribute
605 * @len_attr: If not NULL and the WPS attribute is found, will set to the
606 * length of the entire WPS attribute
608 * Returns: the address of the specific WPS attribute found, or NULL
654 * rtw_get_wps_attr_content23a - Search a specific WPS attribute content
658 * @target_attr_id: The attribute ID of WPS attribute to search
659 * @buf_content: If not NULL and the WPS attribute is found, WPS attribute
661 * @len_content: If not NULL and the WPS attribute is found, will set to the
662 * length of the WPS attribute content
664 * Returns: the address of the specific WPS attribute content found, or NULL
/linux-4.1.27/drivers/pcmcia/
H A Dbcm63xx_pcmcia.h51 /* attribute/common memory resources */
H A Dsoc_common.h159 * common and attribute memory write timing) says that twWE has a
168 * PCMCIA I/O command width time is 165ns. The default PCMCIA 5V attribute
169 * and memory command width time is 150ns; the PCMCIA 3.3V attribute and
/linux-4.1.27/drivers/tty/ipwireless/
H A Dmain.h51 /* Reference to attribute memory, containing CIS data */
/linux-4.1.27/drivers/platform/mips/
H A Dcpu_hwmon.c37 static struct attribute *cpu_hwmon_attributes[] = {
42 /* Hwmon device attribute group */
68 static const struct attribute *hwmon_cputemp1[] = {
74 static const struct attribute *hwmon_cputemp2[] = {
/linux-4.1.27/arch/powerpc/include/asm/
H A Dfsl_pamu_stash.h30 * This attribute allows configuring stashig specific parameters
H A Dpte-44x.h9 * the attribute are difficult to map in such a fashion that they
12 * upper word of the PTE and the attribute bits below are packed
24 * PPC 440 core has following TLB attribute fields;
/linux-4.1.27/arch/m68k/include/asm/
H A Dmcfwdebug.h16 #define MCFDEBUG_BAAR 0x5 /* BDM address attribute */
17 #define MCFDEBUG_AATR 0x6 /* Address attribute trigger */
61 /* Constants for the address attribute trigger register */
82 /* Constants for the BDM address attribute register */
/linux-4.1.27/fs/exofs/
H A Dsys.c28 struct attribute attr;
33 static ssize_t odev_attr_show(struct kobject *kobj, struct attribute *attr, odev_attr_show()
42 static ssize_t odev_attr_store(struct kobject *kobj, struct attribute *attr, odev_attr_store()
102 static struct attribute *odev_attrs[] = {
/linux-4.1.27/drivers/firmware/
H A Ddmi-sysfs.c10 * DMI attributes are presented in attribute files with names
49 /* dmi_sysfs_attribute - Top level attribute. used by all entries. */
51 struct attribute attr;
66 struct attribute attr;
91 static struct dmi_sysfs_attribute *to_attr(struct attribute *attr) to_attr()
97 struct attribute *_attr, char *buf) dmi_sysfs_attr_show()
197 struct attribute *attr;
214 struct attribute *attr, dmi_entry_attr_show()
222 * normalized show method hanging off of the attribute */ dmi_entry_attr_show()
290 static struct attribute *dmi_sysfs_sel_attrs[] = {
511 static struct attribute *dmi_sysfs_entry_attrs[] = {
/linux-4.1.27/arch/x86/lib/
H A Dinat.c2 * x86 instruction attribute tables
90 /* If this is not a group, get attribute directly */ inat_get_avx_attribute()
/linux-4.1.27/block/
H A Dblk-mq-sysfs.c21 struct attribute attr;
27 struct attribute attr;
32 static ssize_t blk_mq_sysfs_show(struct kobject *kobj, struct attribute *attr, blk_mq_sysfs_show()
55 static ssize_t blk_mq_sysfs_store(struct kobject *kobj, struct attribute *attr, blk_mq_sysfs_store()
79 struct attribute *attr, char *page) blk_mq_hw_sysfs_show()
102 struct attribute *attr, const char *page, blk_mq_hw_sysfs_store()
266 static struct attribute *default_ctx_attrs[] = {
303 static struct attribute *default_hw_ctx_attrs[] = {
/linux-4.1.27/arch/s390/pci/
H A Dpci_sysfs.c78 static struct attribute *zpci_dev_attrs[] = {
94 static struct attribute *pfip_attrs[] = {
/linux-4.1.27/drivers/usb/misc/
H A Dcypress_cy7c63.c150 /* attribute callback handler (write) */ set_port0_handler()
158 /* attribute callback handler (write) */ set_port1_handler()
184 /* attribute callback handler (read) */ get_port0_handler()
191 /* attribute callback handler (read) */ get_port1_handler()
221 /* create device attribute files */ cypress_probe()
251 /* remove device attribute files */ cypress_disconnect()
/linux-4.1.27/include/scsi/fc/
H A Dfc_fcp.h52 __u8 fc_pri_ta; /* priority and task attribute */
64 __u8 fc_pri_ta; /* priority and task attribute */
77 #define FCP_PTA_SIMPLE 0 /* simple task attribute */
78 #define FCP_PTA_HEADQ 1 /* head of queue task attribute */
79 #define FCP_PTA_ORDERED 2 /* ordered task attribute */
81 #define FCP_PTA_MASK 7 /* mask for task attribute field */
/linux-4.1.27/sound/hda/
H A Dhdac_sysfs.c48 static struct attribute *hdac_dev_attrs[] = {
79 struct attribute attr;
100 static ssize_t widget_attr_show(struct kobject *kobj, struct attribute *attr, widget_attr_show()
116 static ssize_t widget_attr_store(struct kobject *kobj, struct attribute *attr, widget_attr_store()
271 static struct attribute *widget_node_attrs[] = {
284 static struct attribute *widget_afg_attrs[] = {
/linux-4.1.27/drivers/xen/
H A Dsys-hypervisor.c32 struct attribute attr;
94 static struct attribute *version_attrs[] = {
218 static struct attribute *xen_compile_attrs[] = {
347 static struct attribute *xen_properties_attrs[] = {
421 struct attribute *attr, hyp_sysfs_show()
432 struct attribute *attr, hyp_sysfs_store()
/linux-4.1.27/drivers/scsi/pm8001/
H A Dpm8001_ctl.c52 * A sysfs 'read-only' shost attribute.
77 * A sysfs 'read-only' shost attribute.
106 * A sysfs 'read-only' shost attribute.
129 * A sysfs 'read-only' shost attribute.
155 * A sysfs 'read-only' shost attribute.
199 * A sysfs 'read-only' shost attribute.
228 * A sysfs 'read-only' shost attribute.
247 * A sysfs 'read/write' shost attribute.
280 * A sysfs 'read-only' shost attribute.
315 * A sysfs 'read-only' shost attribute.
347 * A sysfs 'read-only' shost attribute.
379 * A sysfs 'read-only' shost attribute.
417 * A sysfs 'read-only' shost attribute.
453 ** A sysfs 'read-only' shost attribute.
472 **A sysfs 'read-only' shost attribute.
/linux-4.1.27/drivers/scsi/lpfc/
H A Dlpfc_attr.c97 * @attr: device attribute, not used.
112 * @attr: device attribute, not used.
189 * @attr: device attribute, not used.
206 * @attr: device attribute, not used.
225 * @attr: device attribute, not used.
247 * @attr: device attribute, not used.
266 * @attr: device attribute, not used.
285 * @attr: device attribute, not used.
304 * @attr: device attribute, not used.
323 * @attr: device attribute, not used.
342 * @attr: device attribute, not used.
376 * @attr: device attribute, not used.
397 * @attr: device attribute, not used.
421 * @attr: device attribute, not used.
511 * @attr: device attribute, not used.
540 * @attr: device attribute, not used.
560 * @attr: device attribute, not used.
595 * @attr: device attribute, not used.
797 * @attr: device attribute, not used.
1005 * @attr: device attribute, not used.
1024 * @attr: device attribute, not used.
1053 * @attr: device attribute, not used.
1237 * @attr: device attribute, not used.
1265 * @attr: device attribute, not used.
1293 * @attr: device attribute, not used.
1321 * @attr: device attribute, not used.
1349 * @attr: device attribute, not used.
1377 * @attr: device attribute, not used.
1405 * @attr: device attribute, not used.
1433 * @attr: device attribute, not used.
1455 * @attr: device attribute, not used.
1540 * @attr: device attribute, not used.
1559 * @attr: device attribute, not used.
1578 * @attr: device attribute, not used.
1600 * @attr: device attribute, not used.
1624 * lpfc_param_show - Return a cfg attribute value in decimal
1632 * @attr: device attribute, not used.
1633 * @buf: on return contains the attribute value in decimal.
1652 * lpfc_param_hex_show - Return a cfg attribute value in hex
1660 * @attr: device attribute, not used.
1661 * @buf: on return contains the attribute value in hexadecimal.
1680 * lpfc_param_init - Initializes a cfg attribute
1687 * lpfc_##attr##_init: Initializes an attribute.
1689 * @val: integer attribute value.
1707 "0449 lpfc_"#attr" attribute cannot be set to %d, "\
1714 * lpfc_param_set - Set a cfg attribute value
1720 * lpfc_##attr##_set: Sets an attribute value.
1722 * @val: integer attribute value.
1745 "0450 lpfc_"#attr" attribute cannot be set to %d, "\
1751 * lpfc_param_store - Set a vport attribute value
1759 * @attr: device attribute, not used.
1760 * @buf: contains the attribute value in ascii.
1791 * lpfc_vport_param_show - Return decimal formatted cfg attribute value
1797 * lpfc_##attr##_show: prints the attribute value in decimal.
1799 * @attr: device attribute, not used.
1800 * @buf: on return contains the attribute value in decimal.
1817 * lpfc_vport_param_hex_show - Return hex formatted attribute value
1824 * lpfc_##attr##_show: prints the attribute value in hexadecimal.
1826 * @attr: device attribute, not used.
1827 * @buf: on return contains the attribute value in hexadecimal.
1844 * lpfc_vport_param_init - Initialize a vport cfg attribute
1855 * @val: integer attribute value.
1870 "0423 lpfc_"#attr" attribute cannot be set to %d, "\
1877 * lpfc_vport_param_set - Set a vport cfg attribute
1887 * @val: integer attribute value.
1907 "0424 lpfc_"#attr" attribute cannot be set to %d, "\
1913 * lpfc_vport_param_store - Set a vport attribute
1922 * @buf: contains the attribute value in decimal.
2133 * @attr: device attribute, not used.
2153 * the soft_wwpn attribute to be settable. Once the attribute lpfc_soft_wwn_enable_store()
2156 * attribute. lpfc_soft_wwn_enable_store()
2180 * @attr: device attribute, not used.
2200 * @attr: device attribute, not used.
2259 "0463 lpfc_soft_wwpn attribute set failed to " lpfc_soft_wwpn_store()
2270 "0464 lpfc_soft_wwpn attribute set failed to " lpfc_soft_wwpn_store()
2280 * @attr: device attribute, not used.
2345 * @attr: device attribute, not used.
2366 * @attr: device attribute, not used.
2413 * @attr: device attribute, not used.
2434 * @attr: device attribute, not used.
2482 * @attr: device attribute, not used.
2503 * @attr: device attribute, not used.
2544 * @attr: device attribute, not used.
2670 * @attr: device attribute, not used.
2716 * @attr: device attribute, not used.
2889 * @attr: device attribute, not used.
2938 "0400 lpfc_nodev_tmo attribute cannot be set to" lpfc_nodev_tmo_init()
3003 "0403 lpfc_nodev_tmo attribute cannot be set to" lpfc_nodev_tmo_set()
3054 "0404 lpfc_devloss_tmo attribute cannot be set to" lpfc_devloss_tmo_set()
3157 "0422 lpfc_restrict_login attribute cannot " lpfc_restrict_login_init()
3192 "0425 lpfc_restrict_login attribute cannot " lpfc_restrict_login_set()
3310 "%d:0467 lpfc_topology attribute cannot be set to %d, " lpfc_topology_store()
3327 * @attr: device attribute structure.
3349 * Sysfs attribute to control the statistical data collection.
3577 * Sysfs attribute to control the statistical data collection.
3596 * sysfs_drvr_stat_data_read - Read function for lpfc_drvr_stat_data attribute
3736 "2879 lpfc_link_speed attribute cannot be set " lpfc_link_speed_store()
3744 "3112 lpfc_link_speed attribute cannot be set " lpfc_link_speed_store()
3764 "0469 lpfc_link_speed attribute cannot be set to %d, " lpfc_link_speed_store()
3806 "0405 lpfc_link_speed attribute cannot " lpfc_link_speed_init()
3827 * @attr: device attribute, not used.
3936 "2712 lpfc_aer_support attribute value %d out " lpfc_aer_support_init()
3950 * @attr: device attribute, not used.
3998 * @attr: device attribute, not used.
4128 * @attr: device attribute, not used.
4199 * @attr: device attribute, not used.
4296 * @attr: device attribute, not used.
4376 * @attr: device attribute, not used.
4581 # bit 2 = All attributes Use a attribute subset
H A Dlpfc_ct.c1491 /* point to the HBA attribute block */ lpfc_fdmi_cmd()
1503 * Point to beginning of first HBA attribute entry lpfc_fdmi_cmd()
1505 /* #1 HBA attribute entry */ lpfc_fdmi_cmd()
1521 /* #2 HBA attribute entry */ lpfc_fdmi_cmd()
1539 /* #3 HBA attribute entry */ lpfc_fdmi_cmd()
1557 /* #4 HBA attribute entry */ lpfc_fdmi_cmd()
1574 /* #5 HBA attribute entry */ lpfc_fdmi_cmd()
1591 /* #6 HBA attribute entry */ lpfc_fdmi_cmd()
1618 /* #7 HBA attribute entry */ lpfc_fdmi_cmd()
1636 /* #8 HBA attribute entry */ lpfc_fdmi_cmd()
1654 /* #9 HBA attribute entry */ lpfc_fdmi_cmd()
1672 /* #10 HBA attribute entry */ lpfc_fdmi_cmd()
1693 /* #11 HBA attribute entry */ lpfc_fdmi_cmd()
1714 /* #12 HBA attribute entry */ lpfc_fdmi_cmd()
1760 /* #1 Port attribute entry */ lpfc_fdmi_cmd()
1774 /* #2 Port attribute entry */ lpfc_fdmi_cmd()
1799 /* #3 Port attribute entry */ lpfc_fdmi_cmd()
1832 /* #4 Port attribute entry */ lpfc_fdmi_cmd()
1851 /* #5 Port attribute entry */ lpfc_fdmi_cmd()
1869 /* #6 Port attribute entry */ lpfc_fdmi_cmd()
1895 /* #7 Port attribute entry */ lpfc_fdmi_cmd()
1911 /* #8 Port attribute entry */ lpfc_fdmi_cmd()
1927 /* #9 Port attribute entry */ lpfc_fdmi_cmd()
1942 /* #10 Port attribute entry */ lpfc_fdmi_cmd()
1954 /* #11 Port attribute entry */ lpfc_fdmi_cmd()
1968 /* #12 Port attribute entry */ lpfc_fdmi_cmd()
1984 /* #13 Port attribute entry */ lpfc_fdmi_cmd()
2000 /* #257 Port attribute entry */ lpfc_fdmi_cmd()
2012 /* #258 Port attribute entry */ lpfc_fdmi_cmd()
2025 /* #259 Port attribute entry */ lpfc_fdmi_cmd()
/linux-4.1.27/drivers/scsi/
H A Discsi_boot_sysfs.c29 * The kobject and attribute structures.
32 struct attribute attr;
41 struct attribute *attr, char *buf) iscsi_boot_show_attribute()
99 static struct attribute *target_attrs[] = {
116 struct attribute *attr, int i) iscsi_boot_tgt_attr_is_visible()
180 static struct attribute *ethernet_attrs[] = {
197 struct attribute *attr, int i) iscsi_boot_eth_attr_is_visible()
257 static struct attribute *initiator_attrs[] = {
269 struct attribute *attr, int i) iscsi_boot_ini_attr_is_visible()
/linux-4.1.27/net/wimax/
H A Dop-msg.c37 * Messages are encoded as a binary netlink attribute using nla_put()
147 dev_err(dev, "no memory to add ifindex attribute\n"); wimax_msg_alloc()
154 dev_err(dev, "no memory to add pipe_name attribute\n"); wimax_msg_alloc()
161 "attribute: %d\n", msg, size, result); wimax_msg_alloc()
192 pr_err("Cannot find attribute WIMAX_GNL_MSG_DATA\n"); wimax_msg_data_len()
214 pr_err("Cannot find attribute WIMAX_GNL_MSG_DATA\n"); wimax_msg_data()
235 pr_err("Cannot find attribute WIMAX_GNL_MSG_DATA\n"); wimax_msg_len()
346 pr_err("WIMAX_GNL_MSG_FROM_USER: can't find IFIDX attribute\n"); wimax_gnl_doit_msg_from_user()
359 "attribute\n"); wimax_gnl_doit_msg_from_user()
/linux-4.1.27/drivers/rtc/
H A Drtc-hid-sensor-time.c100 * the range for the year attribute. Therefor we support hid_time_capture_sample()
175 "attribute '%s' not 8, 16 or 32 bits wide!\n", hid_time_parse_report()
182 /* allow attribute seconds with unit seconds */ hid_time_parse_report()
188 "attribute '%s' hasn't a unit of type 'none'!\n", hid_time_parse_report()
195 "attribute '%s' hasn't a unit exponent of 1!\n", hid_time_parse_report()
/linux-4.1.27/arch/powerpc/perf/req-gen/
H A Dperf.h127 * Define event attribute array
128 * static struct attribute *hv_gpci_event_attrs[] = {
140 static __maybe_unused struct attribute *hv_gpci_event_attrs[] = {
/linux-4.1.27/drivers/iommu/
H A Diommu-sysfs.c21 static struct attribute *devices_attr[] = {
54 * attributes can be provided as an attribute group, allowing a unique
/linux-4.1.27/drivers/iio/trigger/
H A Diio-trig-sysfs.c67 static struct attribute *iio_sysfs_trig_attrs[] = {
115 static struct attribute *iio_sysfs_trigger_attrs[] = {
/linux-4.1.27/drivers/net/bonding/
H A Dbond_sysfs_slave.c18 struct attribute attr;
97 struct attribute *attr, char *buf) slave_show()
/linux-4.1.27/arch/x86/boot/
H A Dmemory.c43 * other attribute bits. Revisit this if we see the extended detect_memory_e820()
44 * attribute bits deployed in a meaningful way in the future. detect_memory_e820()
/linux-4.1.27/drivers/gpu/drm/ttm/
H A Dttm_memory.c53 static struct attribute ttm_mem_sys = {
57 static struct attribute ttm_mem_emer = {
61 static struct attribute ttm_mem_max = {
65 static struct attribute ttm_mem_swap = {
69 static struct attribute ttm_mem_used = {
85 struct attribute *attr, ttm_mem_zone_show()
112 struct attribute *attr, ttm_mem_zone_store()
149 static struct attribute *ttm_mem_zone_attrs[] = {
/linux-4.1.27/drivers/infiniband/core/
H A Dsysfs.c52 struct attribute attr;
71 struct attribute *attr, char *buf) port_attr_show()
271 static struct attribute *port_default_attrs[] = {
401 static struct attribute *pma_attrs[] = {
429 struct attribute *a; ib_port_release()
477 static struct attribute ** alloc_group_attrs()
482 struct attribute **tab_attr; alloc_group_attrs()
486 tab_attr = kcalloc(1 + len, sizeof(struct attribute *), GFP_KERNEL); alloc_group_attrs()
705 /* Show a given an attribute in the statistics group */ show_protocol_stat()
722 /* generate a read-only iwarp statistics attribute */
772 static struct attribute *iw_proto_stats_attrs[] = {
H A Diwpm_msg.c86 err_str = "Unable to put attribute of the nlmsg"; iwpm_register_pid()
166 err_str = "Unable to put attribute of the nlmsg"; iwpm_add_mapping()
239 err_str = "Unable to put attribute of the nlmsg"; iwpm_add_and_query_mapping()
305 err_str = "Unable to put attribute of the nlmsg"; iwpm_remove_mapping()
333 /* netlink attribute policy for the received response to register pid request */
402 /* netlink attribute policy for the received response to add mapping request */
471 /* netlink attribute policy for the response to add and query mapping request
633 /* netlink attribute policy for the received request for mapping info */
684 /* netlink attribute policy for the received mapping info ack */
714 /* netlink attribute policy for the received port mapper error message */
/linux-4.1.27/drivers/infiniband/hw/qib/
H A Dqib_sysfs.c183 struct attribute attr;
195 static struct attribute *port_default_attributes[] = {
297 struct attribute *attr, char *buf) qib_portattr_show()
308 struct attribute *attr, const char *buf, size_t len) qib_portattr_store()
339 struct attribute attr;
360 static struct attribute *sl2vl_default_attributes[] = {
380 static ssize_t sl2vl_attr_show(struct kobject *kobj, struct attribute *attr, sl2vl_attr_show()
413 struct attribute attr;
433 static struct attribute *diagc_default_attributes[] = {
452 static ssize_t diagc_attr_show(struct kobject *kobj, struct attribute *attr, diagc_attr_show()
464 static ssize_t diagc_attr_store(struct kobject *kobj, struct attribute *attr, diagc_attr_store()
/linux-4.1.27/drivers/isdn/hisax/
H A Dq931.c476 dp += sprintf(dp, " diag attribute %d ", *p++ & 0x7f); prcause()
1331 dp += sprintf(dp, " Codeset %d attribute %x attribute size %d\n", cset, *buf, buf[1]); dlogframe()
1342 dp += sprintf(dp, " Codeset %d attribute %x attribute size %d\n", cset, *buf, buf[1]); dlogframe()
1344 dp += sprintf(dp, " Unknown Codeset %d attribute %x attribute size %d\n", cset, *buf, buf[1]); dlogframe()
1405 dp += sprintf(dp, " attribute %x attribute size %d\n", *buf, buf[1]); dlogframe()
1416 dp += sprintf(dp, " attribute %x attribute size %d\n", *buf, buf[1]); dlogframe()
1427 dp += sprintf(dp, " attribute %x attribute size %d\n", *buf, buf[1]); dlogframe()
1429 dp += sprintf(dp, " Unknown Codeset %d attribute %x attribute size %d\n", cset, *buf, buf[1]); dlogframe()
1503 dp += sprintf(dp, " attribute %x attribute size %d\n", *buf, buf[1]); dlogframe()
/linux-4.1.27/drivers/isdn/gigaset/
H A Dproc.c79 pr_err("could not create sysfs attribute\n"); gigaset_init_dev_sysfs()
/linux-4.1.27/drivers/leds/
H A Dled-class-flash.c219 static struct attribute *led_flash_strobe_attrs[] = {
224 static struct attribute *led_flash_timeout_attrs[] = {
230 static struct attribute *led_flash_brightness_attrs[] = {
236 static struct attribute *led_flash_fault_attrs[] = {
/linux-4.1.27/drivers/mfd/
H A Dwm831x-otp.c75 dev_err(wm831x->dev, "Unique ID attribute not created: %d\n", wm831x_otp_init()
/linux-4.1.27/drivers/misc/genwqe/
H A Dcard_sysfs.c246 static struct attribute *genwqe_attributes[] = {
261 static struct attribute *genwqe_normal_attributes[] = {
272 * genwqe_is_visible() - Determine if sysfs attribute should be visible or not
278 struct attribute *attr, int n) genwqe_is_visible()
/linux-4.1.27/drivers/rapidio/
H A Drio-sysfs.c101 static struct attribute *rio_dev_attrs[] = {
283 pr_warning("RIO: Failed to create attribute file(s) for %s\n", rio_create_sysfs_dev_files()
331 static struct attribute *rio_bus_attrs[] = {
370 static struct attribute *rio_mport_attrs[] = {
/linux-4.1.27/drivers/staging/rtl8723au/include/
H A Dwifi.h49 /* WPS attribute ID */
/linux-4.1.27/drivers/staging/rtl8188eu/core/
H A Drtw_ieee80211.c782 * rtw_get_wps_attr - Search a specific WPS attribute from a given WPS IE
785 * @target_attr_id: The attribute ID of WPS attribute to search
786 * @buf_attr: If not NULL and the WPS attribute is found, WPS attribute will be copied to the buf starting from buf_attr
787 * @len_attr: If not NULL and the WPS attribute is found, will set to the length of the entire WPS attribute
789 * Returns: the address of the specific WPS attribute found, or NULL
828 * rtw_get_wps_attr_content - Search a specific WPS attribute content from a given WPS IE
831 * @target_attr_id: The attribute ID of WPS attribute to search
832 * @buf_content: If not NULL and the WPS attribute is found, WPS attribute content will be copied to the buf starting from buf_content
833 * @len_content: If not NULL and the WPS attribute is found, will set to the length of the WPS attribute content
835 * Returns: the address of the specific WPS attribute content found, or NULL
/linux-4.1.27/drivers/video/fbdev/omap2/dss/
H A Ddisplay-sysfs.c244 struct attribute attr;
268 static struct attribute *display_sysfs_attrs[] = {
280 static ssize_t display_attr_show(struct kobject *kobj, struct attribute *attr, display_attr_show()
295 static ssize_t display_attr_store(struct kobject *kobj, struct attribute *attr, display_attr_store()
H A Doverlay-sysfs.c363 struct attribute attr;
391 static struct attribute *overlay_sysfs_attrs[] = {
405 static ssize_t overlay_attr_show(struct kobject *kobj, struct attribute *attr, overlay_attr_show()
420 static ssize_t overlay_attr_store(struct kobject *kobj, struct attribute *attr, overlay_attr_store()
/linux-4.1.27/fs/hfsplus/
H A Dhfsplus_raw.h66 * for name of extended attribute
366 /* HFS+ fork data attribute */
373 /* HFS+ extension attribute */
382 /* HFS+ attribute inline data */
/linux-4.1.27/include/scsi/
H A Dosd_attributes.h7 * Contains types and constants that define attribute pages and attribute
288 * each attribute is of the form below. Total array length is deduced
289 * from the attribute's length
/linux-4.1.27/include/linux/platform_data/
H A Dmailbox-omap.h24 * struct omap_mbox_dev_info - OMAP mailbox device attribute info
/linux-4.1.27/include/uapi/linux/netfilter/
H A Dnfnetlink_compat.h19 * with attribute type.
/linux-4.1.27/arch/powerpc/platforms/pseries/
H A Dpower.c59 static struct attribute *g[] = {
/linux-4.1.27/arch/powerpc/perf/
H A Dhv-24x7.c114 static struct attribute *format_attrs[] = {
316 static struct attribute *device_str_attr_create_(char *name, char *str) device_str_attr_create_()
331 static struct attribute *device_str_attr_create(char *name, int name_max, device_str_attr_create()
337 struct attribute *a; device_str_attr_create()
362 static void device_str_attr_destroy(struct attribute *attr) device_str_attr_destroy()
372 static struct attribute *event_to_attr(unsigned ix, event_to_attr()
380 struct attribute *attr; event_to_attr()
416 static struct attribute *event_to_desc_attr(struct hv_24x7_event_data *event, event_to_desc_attr()
430 static struct attribute * event_to_long_desc_attr()
444 static ssize_t event_data_to_attrs(unsigned ix, struct attribute **attrs, event_data_to_attrs()
650 static int create_events_from_catalog(struct attribute ***events_, create_events_from_catalog()
651 struct attribute ***event_descs_, create_events_from_catalog()
652 struct attribute ***event_long_descs_) create_events_from_catalog()
661 struct attribute **events, **event_descs, **event_long_descs; create_events_from_catalog()
821 /* Iterate over the catalog filling in the attribute vector */ create_events_from_catalog()
987 static struct attribute *if_attrs[] = {
/linux-4.1.27/Documentation/networking/
H A Dcxacru-cf.py19 # Output: values string suitable for the sysfs adsl_config attribute
/linux-4.1.27/net/ieee802154/
H A Dsysfs.c58 static struct attribute *pmib_attrs[] = {
/linux-4.1.27/security/selinux/ss/
H A Dconstraint.h41 u32 attr; /* attribute */
/linux-4.1.27/sound/firewire/oxfw/
H A Doxfw-control.c39 buf[5] = 0x10; /* control attribute: current */ oxfw_mute_command()
75 enum control_attribute attribute, oxfw_volume_command()
97 buf[5] = attribute; /* control attribute */ oxfw_volume_command()
73 oxfw_volume_command(struct snd_oxfw *oxfw, s16 *value, unsigned int channel, enum control_attribute attribute, enum control_action action) oxfw_volume_command() argument
/linux-4.1.27/include/drm/
H A Ddrm_gem_cma_helper.h47 /* set vm_flags and we can change the VM attribute to other one at here */
/linux-4.1.27/drivers/media/dvb-frontends/
H A Ddib9000.c203 static int dib9000_risc_apb_access_read(struct dib9000_state *state, u32 address, u16 attribute, const u8 * tx, u32 txlen, u8 * b, u32 len);
204 static int dib9000_risc_apb_access_write(struct dib9000_state *state, u32 address, u16 attribute, const u8 * b, u32 len);
228 static u16 dib9000_read16_attr(struct dib9000_state *state, u16 reg, u8 * b, u32 len, u16 attribute) dib9000_read16_attr() argument
235 return dib9000_risc_apb_access_read(state, reg, attribute, NULL, 0, b, len); dib9000_read16_attr()
250 if (attribute & DATA_BUS_ACCESS_MODE_8BIT) dib9000_read16_attr()
252 if (attribute & DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT) dib9000_read16_attr()
268 if (!(attribute & DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT)) dib9000_read16_attr()
302 static inline u16 dib9000_read_word_attr(struct dib9000_state *state, u16 reg, u16 attribute) dib9000_read_word_attr() argument
305 attribute) != 0) dib9000_read_word_attr()
310 #define dib9000_read16_noinc_attr(state, reg, b, len, attribute) dib9000_read16_attr(state, reg, b, len, (attribute) | DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT)
312 static u16 dib9000_write16_attr(struct dib9000_state *state, u16 reg, const u8 * buf, u32 len, u16 attribute) dib9000_write16_attr() argument
320 (state, reg, DATA_BUS_ACCESS_MODE_16BIT | DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT | attribute, buf, len) != 0) dib9000_write16_attr()
334 if (attribute & DATA_BUS_ACCESS_MODE_8BIT) dib9000_write16_attr()
336 if (attribute & DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT) dib9000_write16_attr()
349 if (!(attribute & DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT)) dib9000_write16_attr()
377 static inline int dib9000_write_word_attr(struct dib9000_state *state, u16 reg, u16 val, u16 attribute) dib9000_write_word_attr() argument
380 return dib9000_write16_attr(state, reg, b, 2, attribute); dib9000_write_word_attr()
385 #define dib9000_write16_noinc_attr(state, reg, buf, len, attribute) dib9000_write16_attr(state, reg, buf, len, DATA_BUS_ACCESS_MODE_NO_ADDRESS_INCREMENT | (attribute))
1008 static int dib9000_risc_apb_access_read(struct dib9000_state *state, u32 address, u16 attribute, const u8 * tx, u32 txlen, u8 * b, u32 len) dib9000_risc_apb_access_read() argument
1016 /* dprintk( "APB access thru rd fw %d %x", address, attribute); */ dib9000_risc_apb_access_read()
1020 dib9000_mbx_send_attr(state, OUT_MSG_BRIDGE_APB_R, mb, 2, attribute); dib9000_risc_apb_access_read()
1021 switch (dib9000_mbx_get_message_attr(state, IN_MSG_END_BRIDGE_APB_RW, mb, &s, attribute)) { dib9000_risc_apb_access_read()
1035 static int dib9000_risc_apb_access_write(struct dib9000_state *state, u32 address, u16 attribute, const u8 * b, u32 len) dib9000_risc_apb_access_write() argument
1046 /* dprintk( "APB access thru wr fw %d %x", address, attribute); */ dib9000_risc_apb_access_write()
1054 dib9000_mbx_send_attr(state, OUT_MSG_BRIDGE_APB_W, mb, (3 + len) / 2, attribute); dib9000_risc_apb_access_write()
1055 return dib9000_mbx_get_message_attr(state, IN_MSG_END_BRIDGE_APB_RW, mb, &s, attribute) == 1 ? 0 : -EINVAL; dib9000_risc_apb_access_write()
/linux-4.1.27/drivers/scsi/fnic/
H A Dfcpio.h212 u8 pri_ta; /* SCSI Priority and Task attribute */
234 #define FCPIO_ICMND_PTA_SIMPLE 0 /* simple task attribute */
235 #define FCPIO_ICMND_PTA_HEADQ 1 /* head of queue task attribute */
236 #define FCPIO_ICMND_PTA_ORDERED 2 /* ordered task attribute */
260 u8 pri_ta; /* SCSI Priority and Task attribute */
534 u8 pri_ta; /* SCSI Priority and Task attribute */
546 #define FCPIO_TCMND_PTA_SIMPLE 0 /* simple task attribute */
547 #define FCPIO_TCMND_PTA_HEADQ 1 /* head of queue task attribute */
548 #define FCPIO_TCMND_PTA_ORDERED 2 /* ordered task attribute */
567 u8 pri_ta; /* SCSI Priority and Task attribute */
/linux-4.1.27/drivers/base/power/
H A Dsysfs.c18 * this attribute. All devices have one of the following two values for
26 * Changing this attribute to "on" prevents the driver from power managing
77 * attribute is set to "enabled" by bus type code or device drivers and in
89 * NOTE: The autosuspend_delay_ms attribute and the autosuspend_delay
594 static struct attribute *power_attrs[] = {
611 static struct attribute *wakeup_attrs[] = {
633 static struct attribute *runtime_attrs[] = {
648 static struct attribute *pm_qos_resume_latency_attrs[] = {
657 static struct attribute *pm_qos_latency_tolerance_attrs[] = {
666 static struct attribute *pm_qos_flags_attrs[] = {
/linux-4.1.27/drivers/usb/core/
H A Dsysfs.c321 * no point in creating the attribute file. add_persist_attributes()
534 static struct attribute *usb2_hardware_lpm_attr[] = {
545 static struct attribute *power_attrs[] = {
680 static struct attribute *dev_attrs[] = {
718 static struct attribute *dev_string_attrs[] = {
726 struct attribute *a, int n) dev_string_attrs_are_visible()
769 /* The binary attribute begins with the device descriptor. read_descriptors()
929 static struct attribute *intf_attrs[] = {
944 static struct attribute *intf_assoc_attrs[] = {
954 struct attribute *a, int n) intf_assoc_attrs_are_visible()
/linux-4.1.27/drivers/hwmon/pmbus/
H A Dpmbus_core.c37 * Number of additional attribute pointers to allocate
61 struct device_attribute attribute; member in struct:pmbus_sensor
70 container_of(_attr, struct pmbus_sensor, attribute)
74 struct sensor_device_attribute attribute; member in struct:pmbus_boolean
79 container_of(_attr, struct pmbus_boolean, attribute)
83 struct device_attribute attribute; member in struct:pmbus_label
87 container_of(_attr, struct pmbus_label, attribute)
692 * If the sensor attribute pointers are NULL, the function returns true if
695 * If sensor attribute pointers are provided, a comparison against a specified
698 * sensor values referenced by sensor attribute pointers s1 and s2).
801 static int pmbus_add_attribute(struct pmbus_data *data, struct attribute *attr) pmbus_add_attribute()
864 a = &boolean->attribute; pmbus_add_boolean()
888 a = &sensor->attribute; pmbus_add_sensor()
920 a = &label->attribute; pmbus_add_label()
938 * The pmbus_limit_attr structure describes a single limit attribute
939 * and its associated alarm attribute.
943 u16 sbit; /* Alarm attribute status bit */
948 const char *alarm; /* Alarm attribute name */
952 * The pmbus_sensor_attr structure describes one sensor attribute. This
1041 * Add generic alarm attribute only if there are no individual pmbus_add_sensor_attrs_one()
/linux-4.1.27/arch/x86/kernel/cpu/
H A Dperf_event_amd_iommu.c63 static struct attribute *iommu_format_attrs[] = {
137 static struct attribute *iommu_cpumask_attrs[] = {
404 struct attribute **attrs; _init_events_attrs()
411 attr_group = kzalloc(sizeof(struct attribute *) _init_events_attrs()
416 attrs = (struct attribute **)(attr_group + 1); _init_events_attrs()
/linux-4.1.27/drivers/scsi/mpt3sas/
H A Dmpt3sas_ctl.c2340 * A sysfs 'read-only' shost attribute.
2362 * A sysfs 'read-only' shost attribute.
2386 * A sysfs 'read-only' shost attribute.
2405 * A sysfs 'read-only' shost attribute.
2423 * A sysfs 'read-only' shost attribute.
2443 * A sysfs 'read-only' shost attribute.
2463 * A sysfs 'read-only' shost attribute.
2481 * A sysfs 'read-only' shost attribute.
2499 * A sysfs 'read-only' shost attribute.
2520 * A sysfs 'read-only' shost attribute.
2541 * A sysfs 'read-only' shost attribute.
2561 * A sysfs 'read-only' shost attribute.
2581 * A sysfs 'read-only' shost attribute.
2602 * A sysfs 'read/write' shost attribute.
2638 * A sysfs 'read/write' shost attribute.
2675 * A sysfs 'read-only' shost attribute.
2695 * A sysfs 'read-only' shost attribute.
2731 * A sysfs 'read-only' shost attribute.
2776 * A sysfs 'read/write' shost attribute.
2780 * offset to the same attribute, it will move the pointer.
2841 * A sysfs 'read/write' shost attribute.
2923 * _ctl_diag_trigger_master_show - show the diag_trigger_master attribute
2927 * A sysfs 'read/write' shost attribute.
2947 * _ctl_diag_trigger_master_store - store the diag_trigger_master attribute
2951 * A sysfs 'read/write' shost attribute.
2978 * _ctl_diag_trigger_event_show - show the diag_trigger_event attribute
2982 * A sysfs 'read/write' shost attribute.
3001 * _ctl_diag_trigger_event_store - store the diag_trigger_event attribute
3005 * A sysfs 'read/write' shost attribute.
3032 * _ctl_diag_trigger_scsi_show - show the diag_trigger_scsi attribute
3036 * A sysfs 'read/write' shost attribute.
3055 * _ctl_diag_trigger_scsi_store - store the diag_trigger_scsi attribute
3059 * A sysfs 'read/write' shost attribute.
3085 * _ctl_diag_trigger_scsi_show - show the diag_trigger_mpi attribute
3089 * A sysfs 'read/write' shost attribute.
3108 * _ctl_diag_trigger_mpi_store - store the diag_trigger_mpi attribute
3112 * A sysfs 'read/write' shost attribute.
3180 * A sysfs 'read-only' shost attribute.
3201 * A sysfs 'read-only' shost attribute.
/linux-4.1.27/drivers/infiniband/hw/mlx4/
H A Dsysfs.c201 struct attribute *attr) add_sysfs_port_mcg_attr()
214 struct attribute *attr) del_sysfs_port_mcg_attr()
382 struct attribute *a; mlx4_port_release()
395 struct attribute attr;
402 struct attribute *attr, char *buf) port_attr_show()
414 struct attribute *attr, port_attr_store()
497 static struct attribute ** alloc_group_attrs()
504 struct attribute **tab_attr; alloc_group_attrs()
508 tab_attr = kcalloc(1 + len, sizeof (struct attribute *), GFP_KERNEL); alloc_group_attrs()
/linux-4.1.27/arch/s390/crypto/
H A Dprng.c680 /* chunksize attribute (ro) */ prng_chunksize_show()
689 /* counter attribute (ro) */ prng_counter_show()
708 /* errorflag attribute (ro) */ prng_errorflag_show()
717 /* mode attribute (ro) */ prng_mode_show()
729 /* reseed attribute (w) */ prng_reseed_store()
743 /* reseed limit attribute (rw) */ prng_reseed_limit_show()
774 /* strength attribute (ro) */ prng_strength_show()
783 static struct attribute *prng_sha512_dev_attrs[] = {
793 static struct attribute *prng_tdes_dev_attrs[] = {
/linux-4.1.27/fs/gfs2/
H A Dsys.c33 struct attribute attr;
38 static ssize_t gfs2_attr_show(struct kobject *kobj, struct attribute *attr, gfs2_attr_show()
46 static ssize_t gfs2_attr_store(struct kobject *kobj, struct attribute *attr, gfs2_attr_store()
274 static struct attribute *gfs2_attrs[] = {
508 static struct attribute *lock_module_attrs[] = {
597 static struct attribute *tune_attrs[] = {
/linux-4.1.27/fs/
H A Dxattr.c4 Extended attribute handling.
28 * Check permissions for extended attribute access. This is a bit complicated
35 * We can never set or remove an extended attribute on a read-only xattr_permission()
176 * before retrieving the extended attribute.
211 /* Compare an extended attribute value with the given value */ vfs_xattr_cmp()
319 * Extended attribute SET operations
423 * Extended attribute GET operations
517 * Extended attribute LIST operations
598 * Extended attribute REMOVE operations
775 * any associated extended attribute.
897 * @name: name of the new extended attribute
898 * @value: value of the new xattr. If %NULL, will remove the attribute
964 * Adds an extended attribute to the list
/linux-4.1.27/fs/jfs/
H A Dxattr.c38 * jfs_xattr.c: extended attribute service
44 * Extended attribute lists (jfs_ea_list) consist of an overall size (32 bit
45 * value) and a variable (0 or more) number of extended attribute
46 * entries. Each extended attribute entry (jfs_ea) is a <name,value> double
102 * that are in a recognized namespace. If the attribute is not recognized,
573 printk(KERN_ERR "ea_get: invalid extended attribute\n"); ea_get()
678 * attribute in a different namespace by prefixing it can_set_xattr()
687 * Don't allow setting an attribute in an unknown namespace. can_set_xattr()
858 * If this is a request for a synthetic attribute in the system.* jfs_setxattr()
910 /* Find the named attribute */ __jfs_getxattr()
942 * If this is a request for a synthetic attribute in the system.* jfs_getxattr()
1014 /* Copy attribute names to buffer */ jfs_listxattr()
1038 * If this is a request for a synthetic attribute in the system.* jfs_removexattr()

Completed in 3812 milliseconds

12345678