ELMs and constraints on the H-mode pedestal: peeling–ballooning stability calculation and comparison with experiment