Banks generate income through different product and services like one of the primary ways is by lending money to customers at a higher interest rate than the rate at which they borrow money from other banks or the central bank. The difference in interest rates, known as interest rate spread allows banks to earn a profit on the loans they make. Banks also charge fees for various services such as account maintenance, ATM usage and wire transfer. Banks may invest their own funds in various financial instruments such as stocks, bonds and real estate to earn a profit on their investment. Some banks generate income by providing advisory services to clients or by offering insurance products.
Number one of their income is obviously lending

it could be lending to other bank like credit suisse case or lent to other people, a company or government project or lend their money to the government bond. the point is they generated money from lending. and that is pretty much 90% i think

It can be said that the biggest profit of banks is from their lending sector. But what's wrong with that? Many people say that the bank is taking our money when we deposit money. That's true but it's the art of business, and if we don't like it, we don't have to trust them and no one is forcing us to give them money. Like many people on this forum are also making profit through lending.