There are quite a few international flights come in at that time in the morning to Gatwick, so let us say, it takes you an hour to pass through the lovely UK passport control as a non EU resident, which can be realistic, as you come in after a large Emirates flight from Dubai.
If the flight (from Halifax?) is on time, 1 hour through passport control is 09.25. Half an hour to pick your bags (which should be out before you), dash for the shuttle between North and South terminals and find the Iberia check in. You are at 1 hour before your flight, which is right on the time check on closes. Possible, but at any rate, very stressful, and no time for any delays.
What I would advise, if this is your booked flights, is availing yourself of the premium (fast track) border services at Gatwick, because this could easily knock off 30 minutes queuing through passport control, and those 30 minutes should make a lot of difference.
Go to
www.premium.gatwick.com to buy these, well in advance, as they limit the numbers issued per day.
You can buy fast track passport clearance on arrival for £ 7 per person, and also, separately, buy fast track security for your Madrid flight for £ 5 per person, which, again, should save you 10 minutes, when every minute counts. There is no passport control going out, and one common security area (with the fast track separated).
Small money for what could otherwise mean you miss your onward flight, which probably would be at your cost, as you are not on a through ticket.
Also, pay extra for a seat as far towards the front of the plane on your flight from Canada as your class of ticket allows. Sometimes it can take 20 minutes to physically exit the plane, and you do not have that free time.