Samsung has had an eventful year marred by corruption scandals in South Korea and exploding phones around the world. But that hasn’t stopped the company from posting a record-breaking quarter in terms of profits, helped by a memory chip boom and a solid comeback from the Note 7 fiasco with the well received Galaxy S8 and S8 Plus.

From April through the end of June 2017, Samsung took in $54.8 billion in revenue, with $12.8 billion coming as profit. This is a 72% increase over the same period a year earlier.

The Semiconductor businesses posted 8.03 trillion won in operating profits on consolidated revenue of 17.58 trillion won for the quarter. The Display Panel segment posted 7.71 trillion won in consolidated revenue and 1.71 trillion won in operating profit for the quarter driven by increased sales of premium OLED displays and high-end, large-size LCD panels.

The mobile division reported 30.01 trillion won in consolidated revenue and 4.06 trillion won in operating profit for the quarter.

Looking ahead the company expects its semiconductor business to remain strong, and though not directly mentioned by Samsung, many are expecting a boost to its display segment too as Apple is widely believed to be using Samsung’s OLED technology on the next iPhone. Moreover, Samsung expects mobile earnings to dip in the third quarter as S8 sales trail off, mid- to low-tier models take up a larger share of total shipments, and marketing costs increase for the Galaxy Note 8