Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: Convert AB3500 to new irq_ APIs

The genirq core is being updated to pass struct irq_data rather than irq
numbers into chip drivers. As part of the update assignments to NULL for
unused operations are removed, these are not needed and the genirq docs
should be good enough.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Mattias Wallin <mattias.wallin@stericsson.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>

authored by

Mark Brown and committed by
Samuel Ortiz
c91ad349 0f76aaeb

+13 -15
+13 -15
drivers/mfd/ab3550-core.c
··· 1159 1159 } 1160 1160 } 1161 1161 1162 - static void ab3550_mask(unsigned int irq) 1162 + static void ab3550_mask(struct irq_data *data) 1163 1163 { 1164 1164 unsigned long flags; 1165 1165 struct ab3550 *ab; 1166 1166 struct ab3550_platform_data *plf_data; 1167 + int irq; 1167 1168 1168 - ab = get_irq_chip_data(irq); 1169 + ab = irq_data_get_irq_chip_data(data); 1169 1170 plf_data = ab->i2c_client[0]->dev.platform_data; 1170 - irq -= plf_data->irq.base; 1171 + irq = data->irq - plf_data->irq.base; 1171 1172 1172 1173 spin_lock_irqsave(&ab->event_lock, flags); 1173 1174 ab->event_mask[irq / 8] |= BIT(irq % 8); ··· 1177 1176 schedule_work(&ab->mask_work); 1178 1177 } 1179 1178 1180 - static void ab3550_unmask(unsigned int irq) 1179 + static void ab3550_unmask(struct irq_data *data) 1181 1180 { 1182 1181 unsigned long flags; 1183 1182 struct ab3550 *ab; 1184 1183 struct ab3550_platform_data *plf_data; 1184 + int irq; 1185 1185 1186 - ab = get_irq_chip_data(irq); 1186 + ab = irq_data_get_irq_chip_data(data); 1187 1187 plf_data = ab->i2c_client[0]->dev.platform_data; 1188 - irq -= plf_data->irq.base; 1188 + irq = data->irq - plf_data->irq.base; 1189 1189 1190 1190 spin_lock_irqsave(&ab->event_lock, flags); 1191 1191 ab->event_mask[irq / 8] &= ~BIT(irq % 8); ··· 1195 1193 schedule_work(&ab->mask_work); 1196 1194 } 1197 1195 1198 - static void noop(unsigned int irq) 1196 + static void noop(struct irq_data *data) 1199 1197 { 1200 1198 } 1201 1199 1202 1200 static struct irq_chip ab3550_irq_chip = { 1203 1201 .name = "ab3550-core", /* Keep the same name as the request */ 1204 - .startup = NULL, /* defaults to enable */ 1205 - .shutdown = NULL, /* defaults to disable */ 1206 - .enable = NULL, /* defaults to unmask */ 1207 - .disable = ab3550_mask, /* No default to mask in chip.c */ 1208 - .ack = noop, 1209 - .mask = ab3550_mask, 1210 - .unmask = ab3550_unmask, 1211 - .end = NULL, 1202 + .irq_disable = ab3550_mask, /* No default to mask in chip.c */ 1203 + .irq_ack = noop, 1204 + .irq_mask = ab3550_mask, 1205 + .irq_unmask = ab3550_unmask, 1212 1206 }; 1213 1207 1214 1208 struct ab_family_id {