From: Damien Lespiau Date: Tue, 5 Aug 2014 10:29:37 +0000 (+0100) Subject: drm/i915: Introduce a for_each_intel_encoder() macro X-Git-Tag: fixes-against-v3.18-rc2~73^2~78^2~18 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b2784e151903628a086d2ee12cf943690216cd6c;p=pandora-kernel.git drm/i915: Introduce a for_each_intel_encoder() macro Following the established idom, let's provide a macro to iterate through the encoders. spatch helps, once more, for the substitution: @@ iterator name list_for_each_entry; iterator name for_each_intel_encoder; struct intel_encoder * encoder; struct drm_device * dev; @@ -list_for_each_entry(encoder, &dev->mode_config.encoder_list, base.head) { +for_each_intel_encoder(dev, encoder) { ... } I also modified a few call sites by hand where a pointer to mode_config was directly used (to avoid overflowing 80 chars). Signed-off-by: Damien Lespiau [danvet: Wrap paramters correctly in the macro and remove spurious space checkpatch noticed.] Signed-off-by: Daniel Vetter --- Reading git-diff-tree failed