s64
s64 last_update_us;
s64 accum_us; /* accumulated microseconds */
s64 accum_us_vis; /* for visible VRAM */
static u64 us_to_bytes(struct amdgpu_device *adev, s64 us)
static s64 bytes_to_us(struct amdgpu_device *adev, u64 bytes)
s64 time_us, increment_us;
const s64 us_upper_bound = 200000;
s64 min_us;
s64 result = man->size - atomic64_read(&mgr->available);
s64 kt, kv, leakage_w, i_leakage, vddc;
s64 temperature, t_slope, t_intercept, av, bv, t_ref;
s64 tmp;
s64 kt, kv, leakage_w, i_leakage, vddc;
s64 peak_kbps;
static unsigned long to_wait_timeout(s64 timeout_ns)
s64 priority = args->value;
} else if ((s64)offset < 0) {
if ((s64)offset < 0) {
(s64)ts.tv_sec, ts.tv_nsec / NSEC_PER_USEC);
(s64)ts.tv_sec, ts.tv_nsec / NSEC_PER_USEC);
(s64)ts.tv_sec, ts.tv_nsec / NSEC_PER_USEC);
s64 panel_power_off_duration;
if (panel_power_off_duration < (s64)intel_dp->panel_power_cycle_delay)
static inline s64 drm_fixp_mul(s64 a, s64 b)
s64 result;
static inline s64 drm_fixp_div(s64 a, s64 b)
s64 result;
static inline s64 drm_fixp_from_fraction(s64 a, s64 b)
s64 res;
res = (s64) res_abs;
static inline s64 drm_fixp_exp(s64 x)
s64 tolerance = div64_s64(DRM_FIXED_ONE, 1000000);
s64 sum = DRM_FIXED_ONE, term, y = x;
static inline s64 drm_int2fixp(int a)
return ((s64)a) << DRM_FIXED_POINT;
static inline int drm_fixp2int(s64 a)
return ((s64)a) >> DRM_FIXED_POINT;
static inline int drm_fixp2int_ceil(s64 a)
static inline unsigned drm_fixp_msbset(s64 a)
#define S64_MAX ((s64)(U64_MAX>>1))
typedef s64 ktime_t;
ktime_set(const s64 secs, const unsigned long nsecs)
return (secs * NSEC_PER_SEC) + (s64)nsecs;
static inline s64
static inline s64
static inline s64
s64 kt, kv, leakage_w, i_leakage, vddc, temperature;
static int radeon_dp_mst_set_vcp_size(struct radeon_encoder *mst, s64 avg_time_slots_per_mtp)
s64 fixed_pbn, fixed_pbn_per_slot, avg_time_slots_per_mtp;
s64 kt, kv, leakage_w, i_leakage, vddc;
s64 temperature, t_slope, t_intercept, av, bv, t_ref;
s64 tmp;
s64 kt, kv, leakage_w, i_leakage, vddc;
s64 lat_ns;
s64 value;
lat_ns = ((s64)rxa * 1024 -
(2 * (s64)hw->mac.max_frame_size)) * 8 * 1000;