Lines Matching defs:bytes

513         ALOGE("Invalid bytes value. 1..max_int64.");
617 ALOGE("Invalid bytes value. 1..max_int64.");
669 int BandwidthController::getInterfaceSharedQuota(int64_t *bytes) {
670 return getInterfaceQuota("shared", bytes);
673 int BandwidthController::getInterfaceQuota(const char *costName, int64_t *bytes) {
685 scanRes = fscanf(fp, "%lld", bytes);
686 ALOGV("Read quota res=%d bytes=%lld", scanRes, *bytes);
724 int BandwidthController::updateQuota(const char *quotaName, int64_t bytes) {
735 fprintf(fp, "%lld\n", bytes);
740 int BandwidthController::runIptablesAlertCmd(IptOp op, const char *alertName, int64_t bytes) {
761 bytes, alertName);
766 bytes, alertName);
772 int BandwidthController::runIptablesAlertFwdCmd(IptOp op, const char *alertName, int64_t bytes) {
793 bytes, alertName);
799 int BandwidthController::setGlobalAlert(int64_t bytes) {
803 if (!bytes) {
804 ALOGE("Invalid bytes value. 1..max_int64.");
808 res = updateQuota(alertName, bytes);
810 res = runIptablesAlertCmd(IptOpInsert, alertName, bytes);
813 res |= runIptablesAlertFwdCmd(IptOpInsert, alertName, bytes);
816 globalAlertBytes = bytes;
882 int BandwidthController::setSharedAlert(int64_t bytes) {
887 if (!bytes) {
888 ALOGE("Invalid bytes value. 1..max_int64.");
891 return setCostlyAlert("shared", bytes, &sharedAlertBytes);
898 int BandwidthController::setInterfaceAlert(const char *iface, int64_t bytes) {
901 if (!bytes) {
902 ALOGE("Invalid bytes value. 1..max_int64.");
915 return setCostlyAlert(iface, bytes, &it->alert);
934 int BandwidthController::setCostlyAlert(const char *costName, int64_t bytes, int64_t *alertBytes) {
940 if (!bytes) {
941 ALOGE("Invalid bytes value. 1..max_int64.");
949 asprintf(&alertQuotaCmd, ALERT_IPT_TEMPLATE, "", "-I", chainNameAndPos, bytes, alertName);
954 *alertBytes = bytes;
983 * Parse the ptks and bytes out of:
984 * Chain FORWARD (policy RETURN 0 packets, 0 bytes)
985 * pkts bytes target prot opt in out source destination
1000 int64_t packets, bytes;
1004 iface0[0] = iface1[0] = rest[0] = packets = bytes = 0;
1006 &packets, &bytes, iface0, iface1, rest);
1007 ALOGV("parse res=%d iface0=<%s> iface1=<%s> pkts=%lld bytes=%lld rest=<%s> orig line=<%s>", res,
1008 iface0, iface1, packets, bytes, rest, buffPtr);
1015 ALOGV("iface_in=%s iface_out=%s rx_bytes=%lld rx_packets=%lld ", iface0, iface1, bytes, packets);
1017 stats.rxBytes = bytes;
1019 ALOGV("iface_in=%s iface_out=%s tx_bytes=%lld tx_packets=%lld ", iface1, iface0, bytes, packets);
1021 stats.txBytes = bytes;